X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=POLICY-SDK-APP%2Fsrc%2Fmain%2Fwebapp%2Fapp%2FpolicyApp%2Fpolicy-models%2FEditor%2FPolicyTemplateController%2FClosedLoopPMController.js;h=454a724a95e62b7810b174dc55df92cdb459b8f1;hb=HEAD;hp=c81f4655a0a4af717e8aeaf2f1c7e5dcf8afa89f;hpb=073cc188efe9abb4c010cf674e34e2cf46ef1c52;p=policy%2Fengine.git diff --git a/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/ClosedLoopPMController.js b/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/ClosedLoopPMController.js index c81f4655a..454a724a9 100644 --- a/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/ClosedLoopPMController.js +++ b/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/ClosedLoopPMController.js @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * ONAP Policy Engine * ================================================================================ - * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017, 2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -23,7 +23,14 @@ angular.module("abs").controller('clPMController', ['$scope', '$window', '$timeo $scope.policyNavigator; $scope.savebutton = true; $scope.refreshCheck = false; - + + if(!$scope.temp.policy.editPolicy && !$scope.temp.policy.readOnly){ + $scope.temp.policy = { + policyType : "Config", + configPolicyType : "ClosedLoop_PM" + } + } + $scope.refresh = function(){ if($scope.refreshCheck){ $scope.policyNavigator.refresh(); @@ -35,6 +42,15 @@ angular.module("abs").controller('clPMController', ['$scope', '$window', '$timeo $scope.modal = function(id, hide) { return $('#' + id).modal(hide ? 'hide' : 'show'); }; + + $('#ttlDate').datepicker({ + dateFormat: 'dd/mm/yy', + changeMonth: true, + changeYear: true, + onSelect: function(date) { + angular.element($('#ttlDate')).triggerHandler('input'); + } + }); PolicyAppService.getData('getDictionary/get_OnapNameDataByName').then(function (data) { var j = data; @@ -177,4 +193,4 @@ angular.module("abs").controller('clPMController', ['$scope', '$window', '$timeo }); }; -}]); \ No newline at end of file +}]);