You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by dg...@apache.org on 2018/09/25 17:02:05 UTC
[trafficcontrol] branch 3.0.x updated: flip signed flag when
signingAlgorithm is changed. fixes #2836
This is an automated email from the ASF dual-hosted git repository.
dgelinas pushed a commit to branch 3.0.x
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git
The following commit(s) were added to refs/heads/3.0.x by this push:
new 9cdb2bc flip signed flag when signingAlgorithm is changed. fixes #2836
9cdb2bc is described below
commit 9cdb2bca36657f8d017006c7f03ee532c2d9f57a
Author: Jesse Rivas <je...@comcast.com>
AuthorDate: Fri Sep 21 15:25:52 2018 -0600
flip signed flag when signingAlgorithm is changed. fixes #2836
(cherry picked from commit 1a0770f0f4934e6b24d9d439024bdbe97d7c30a1)
---
.../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>