change management integration with reduce flag
[vid.git] / vid-app-common / src / main / webapp / app / vid / scripts / modals / new-change-management / new-change-management.controller.js
index d966df8..9eed4c1 100644 (file)
                 });
         };
 
-        function isCompatibleVNFRole(vnf) {
+        function isCompatibleNFRole(vnf) {
 
             return vnf.properties['nf-role'] === vm.changeManagement['vnfType'] || !vm.changeManagement['vnfType'];
 
 
         function isValidVnf(vnf) {
 
-            let result =  isCompatibleVNFRole(vnf) && vnf.properties["model-invariant-id"]
+            let result =  isCompatibleNFRole(vnf) && vnf.properties["model-invariant-id"]
                 && vnf.properties["model-version-id"];
 
             return result;
             vm.vnfTypes = [];
             vm.vnfTypesTemp = [];
             vm.serviceInstances = [];
-            vm.fromVNFVersions=[];
-            vm.vnfNames =[];
-            vm.changeManagement.vnfNames =[];
+            vm.fromVNFVersions = [];
+            vm.vnfNames = [];
+            vm.changeManagement.vnfNames = [];
 
             var instances = vm.changeManagement.serviceType["service-instances"]["service-instance"];
             // var promiseArrOfGetVnfs = preparePromiseArrOfGetVnfs(instances);
         };
 
         vm.loadVNFNames = function () {
-            vm.changeManagement.vnfNames =[];
+            vm.changeManagement.vnfNames = [];
             vm.vnfNames = [];
 
             const vnfs = vm.changeManagement.fromVNFVersion ? vm.vnfs : [];
 
                 var selectedVersionNumber = getVersionNameForId(vm.changeManagement.fromVNFVersion);
 
-                if (isCompatibleVNFRole(vnf) &&
+                if (isCompatibleNFRole(vnf) &&
                     selectedVersionNumber === getVersionNameForId(vnf.properties["model-version-id"])) {
                     var vServer = {};