From d4c6d6b3f5ed726c36ce10c2a5892e77c61956da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szekeres=20Ba=CC=81lint?= Date: Sun, 30 Dec 2018 15:13:00 +0100 Subject: [PATCH] fix PHP <-> Python <-> Proxy toggle --- public/assets/js/app.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/public/assets/js/app.js b/public/assets/js/app.js index 2722848..ab70c40 100644 --- a/public/assets/js/app.js +++ b/public/assets/js/app.js @@ -386,6 +386,7 @@ $scope.data.wordpress = $scope.defaultData.wordpress; $scope.data.drupal = $scope.defaultData.drupal; $scope.data.magento = $scope.defaultData.magento; + $scope.data.python = $scope.defaultData.python; $scope.data.proxy = $scope.defaultData.proxy; $scope.data.index = $scope.defaultData.index; $scope.data.fallback_html = $scope.defaultData.fallback_html; @@ -413,7 +414,6 @@ $scope.data.magento = true; break; case 'nodejs': - $scope.data.php = false; $scope.data.proxy = true; break; } @@ -624,6 +624,17 @@ $scope.data.php = false; } + // toggle proxy <-> (PHP || Python) + if ($scope.data.proxy && !oldValue.proxy) { + $scope.data.php = false; + $scope.data.python = false; + } else if ( + ($scope.data.php && !oldValue.php) || + ($scope.data.python && !oldValue.python) + ) { + $scope.data.proxy = false; + } + // default index file if (!$scope.data.php) { $scope.defaultData.index = 'index.html';