Code Review
/
policy
/
engine.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Included Policy GUI Enhancements and validations
[policy/engine.git]
/
POLICY-SDK-APP
/
src
/
main
/
webapp
/
app
/
policyApp
/
policy-models
/
Editor
/
PolicyTemplateController
/
BaseConfigPolicyController.js
diff --git
a/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/BaseConfigPolicyController.js
b/POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/BaseConfigPolicyController.js
index
54ce401
..
02e10bd
100644
(file)
--- a/
POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/BaseConfigPolicyController.js
+++ b/
POLICY-SDK-APP/src/main/webapp/app/policyApp/policy-models/Editor/PolicyTemplateController/BaseConfigPolicyController.js
@@
-25,6
+25,13
@@
app.controller('baseConfigController', ['$scope', 'PolicyAppService', 'policyNav
$scope.savebutton = true;
$scope.refreshCheck = false;
$scope.savebutton = true;
$scope.refreshCheck = false;
+ if(!$scope.temp.policy.editPolicy && !$scope.temp.policy.readOnly){
+ $scope.temp.policy = {
+ policyType : "Config",
+ configPolicyType : "Base"
+ }
+ };
+
$scope.refresh = function(){
if($scope.refreshCheck){
$scope.policyNavigator.refresh();
$scope.refresh = function(){
if($scope.refreshCheck){
$scope.policyNavigator.refresh();
@@
-37,6
+44,15
@@
app.controller('baseConfigController', ['$scope', 'PolicyAppService', 'policyNav
return $('#' + id).modal(hide ? 'hide' : 'show');
};
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;
$scope.data = JSON.parse(j.data);
PolicyAppService.getData('getDictionary/get_OnapNameDataByName').then(function (data) {
var j = data;
$scope.data = JSON.parse(j.data);
@@
-66,14
+82,6
@@
app.controller('baseConfigController', ['$scope', 'PolicyAppService', 'policyNav
}, function (error) {
console.log("failed");
});
}, function (error) {
console.log("failed");
});
-
-
- function extend(obj, src) {
- for (var key in src) {
- if (src.hasOwnProperty(key)) obj[key] = src[key];
- }
- return obj;
- }
$scope.savePolicy = function(policy){
if(policy.itemContent != undefined){
$scope.savePolicy = function(policy){
if(policy.itemContent != undefined){