You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by mi...@apache.org on 2018/09/21 22:05:18 UTC
[trafficcontrol] branch master updated: flip signed flag when
signingAlgorithm is changed. fixes #2836
This is an automated email from the ASF dual-hosted git repository.
mitchell852 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git
The following commit(s) were added to refs/heads/master by this push:
new 1a0770f flip signed flag when signingAlgorithm is changed. fixes #2836
1a0770f is described below
commit 1a0770f0f4934e6b24d9d439024bdbe97d7c30a1
Author: Jesse Rivas <je...@comcast.com>
AuthorDate: Fri Sep 21 15:25:52 2018 -0600
flip signed flag when signingAlgorithm is changed. fixes #2836
---
.../modules/form/deliveryService/FormDeliveryServiceController.js | 8 ++++++++
.../form/deliveryService/form.deliveryService.DNS.tpl.html | 2 +-
.../form/deliveryService/form.deliveryService.HTTP.tpl.html | 2 +-
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/FormDeliveryServiceController.js b/traffic_portal/app/src/common/modules/form/deliveryService/FormDeliveryServiceController.js
index 612b0e4..38002f6 100644
--- a/traffic_portal/app/src/common/modules/form/deliveryService/FormDeliveryServiceController.js
+++ b/traffic_portal/app/src/common/modules/form/deliveryService/FormDeliveryServiceController.js
@@ -236,6 +236,14 @@ var FormDeliveryServiceController = function(deliveryService, dsCurrent, origin,
});
};
+ $scope.changeSigningAlgorithm = function(signingAlgorithm) {
+ if (signingAlgorithm == null) {
+ deliveryService.signed = false;
+ } else {
+ deliveryService.signed = true;
+ }
+ };
+
$scope.viewTargets = function() {
$location.path($location.path() + '/targets');
};
diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html
index ac1ae15..fa8423f 100644
--- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html
+++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html
@@ -390,7 +390,7 @@ under the License.
<span uib-popover-html="label('signingAlgorithm', 'desc')" popover-trigger="click" popover-placement="top" popover-append-to-body="true" popover-class="popover-class">{{label('signingAlgorithm', 'title')}}</span>
</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="signingAlgorithm" class="form-control" ng-model="deliveryService.signingAlgorithm" ng-options="sa.value as sa.label for sa in signingAlgos">
+ <select name="signingAlgorithm" class="form-control" ng-change="changeSigningAlgorithm(deliveryService.signingAlgorithm)" ng-model="deliveryService.signingAlgorithm" ng-options="sa.value as sa.label for sa in signingAlgos">
<option value="">Select...</option>
</select>
<small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.signingAlgorithm != dsCurrent.signingAlgorithm">Current Value: [ {{magicNumberLabel(signingAlgos, dsCurrent.signingAlgorithm)}} ]</small>
diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html
index 980732e..09f1804 100644
--- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html
+++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html
@@ -443,7 +443,7 @@ under the License.
<span uib-popover-html="label('signingAlgorithm', 'desc')" popover-trigger="click" popover-placement="top" popover-append-to-body="true" popover-class="popover-class">{{label('signingAlgorithm', 'title')}}</span>
</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="signingAlgorithm" class="form-control" ng-model="deliveryService.signingAlgorithm" ng-options="sa.value as sa.label for sa in signingAlgos">
+ <select name="signingAlgorithm" class="form-control" ng-change="changeSigningAlgorithm(deliveryService.signingAlgorithm)" ng-model="deliveryService.signingAlgorithm" ng-options="sa.value as sa.label for sa in signingAlgos">
<option value="">Select...</option>
</select>
<small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.signingAlgorithm != dsCurrent.signingAlgorithm">Current Value: [ {{magicNumberLabel(signingAlgos, dsCurrent.signingAlgorithm)}} ]</small>