aboutsummaryrefslogtreecommitdiffstats
path: root/POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js
diff options
context:
space:
mode:
Diffstat (limited to 'POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js')
-rw-r--r--POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js14
1 files changed, 3 insertions, 11 deletions
diff --git a/POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js b/POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js
index b50becf0b..410ef26a0 100644
--- a/POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.js
+++ b/POLICY-SDK-APP/src/main/webapp/app/policyApp/controller/dictionaryController/DecisionRainyDayDictController.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.
@@ -52,7 +52,6 @@ app.controller('editRainyDayDictController' , function ($scope, $modalInstance,
$scope.editRainyDayTreatment = message.rainyDayDictionaryData;
$scope.saveDecisionTreatments = function(rainyDayDictionaryData) {
- var finalData = extend(rainyDayDictionaryData, $scope.treatmentDatas[0]);
var uuu = "saveDictionary/decision_dictionary/save_RainyDay";
var postData={rainyDayDictionaryData: rainyDayDictionaryData, userid: userid};
$.ajax({
@@ -72,18 +71,11 @@ app.controller('editRainyDayDictController' , function ($scope, $modalInstance,
}
},
error : function(data){
- alert("Error while saving.");
+ Notification.error("Error while saving.");
}
});
};
- function extend(obj, src) {
- for (var key in src) {
- if (src.hasOwnProperty(key)) obj[key] = src[key];
- }
- return obj;
- }
-
$scope.treatmentDatas = [{"userDataTypeValues" : $scope.treatments}];
$scope.addNewTreatment = function() {
$scope.treatments.push({});
@@ -97,4 +89,4 @@ app.controller('editRainyDayDictController' , function ($scope, $modalInstance,
$scope.close = function() {
$modalInstance.close();
};
-}); \ No newline at end of file
+});