Feature-9518: Scale-in/Scale-out commands triggered from the UI

 * In NS Instances page. Click "Manual Scaling" in the actions menu.
 * Then a new pop-up page will opened.
 * In the popup there will be a list box which is filled with the all scaling-group-descriptor names captured from all VNFDs in the NSD and whoose scaling-type is "manual".
 * Select scale in / scale out.
 * When the scaling-group-descriptor name and the scaling direction are selected then Click Apply button.
 * The pop-up window is closed and the page is directed to "History of operations" page for this NS.

Change-Id: Iaaa1500bcabea4ebda89f6c11ea91b28396aa42f
Signed-off-by: Barath Kumar R <barath.r@tataelxsi.co.in>
diff --git a/src/models/CommonModel.ts b/src/models/CommonModel.ts
index 7284bbc..2d1c9c3 100644
--- a/src/models/CommonModel.ts
+++ b/src/models/CommonModel.ts
@@ -16,6 +16,8 @@
  Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.in), BARATH KUMAR R (barath.r@tataelxsi.co.in)
  */
 import { HttpHeaders } from '@angular/common/http';
+import { NSD } from 'NSInstanceModel';
+import { VNFD } from 'VNFDModel';
 
 /**
  * @file  Model for Commonly used information.
@@ -48,6 +50,7 @@
     operationalStateFirstStep = 'init',
     operationalStateSecondStep = 'running',
     operationalStateThirdStep = 'failed',
+    operationalStateFourthStep = 'scaling',
     configStateFirstStep = 'init',
     configStateSecondStep = 'configured',
     configStateThirdStep = 'failed',
@@ -108,6 +111,10 @@
     nsConfig?: object;
     projectID?: string;
     username?: string;
+    vnfID?: [];
+    nsID?: string;
+    nsd?: NSD;
+    data?: VNFD[];
 }
 /** Handle the Delete params */
 export interface DELETEPARAMS {
diff --git a/src/models/NSDModel.ts b/src/models/NSDModel.ts
index 131af47..48e7387 100644
--- a/src/models/NSDModel.ts
+++ b/src/models/NSDModel.ts
@@ -34,7 +34,6 @@
 /** Interface for the nscompose descriptors content */
 export interface NSDDetails {
     'connection-point': CONNECTIONPOINT[];
-    'constituent-vnfd': CONSTITUENTVNFD[];
     description: string;
     id: string;
     logo: string;
@@ -57,12 +56,6 @@
     'vld-id-ref': string;
 }
 
-/** Interface for the constituent-vnfd */
-export interface CONSTITUENTVNFD {
-    'member-vnf-index': number;
-    'vnfd-id-ref': string;
-}
-
 /** Interface for the vld */
 export interface VLD {
     id: string;
diff --git a/src/models/NSInstanceModel.ts b/src/models/NSInstanceModel.ts
index 6bafcdd..ce44122 100644
--- a/src/models/NSInstanceModel.ts
+++ b/src/models/NSInstanceModel.ts
@@ -19,7 +19,7 @@
  * @file  Model for NS Instance related information.
  */
 // tslint:disable: completed-docs
-import { CONSTITUENTVNFD, DF, VLD } from 'NSDModel';
+import { DF, VLD } from 'NSDModel';
 import { VNFDAdminDetails } from 'VNFDModel';
 
 /** Interface for NSInstanceDetails */
@@ -34,6 +34,7 @@
     'operational-status': string;
     'datacenter': string;
     nsd: NSD;
+    'nsd-id': string;
     name: string;
     'name-ref': string;
     id: string;
@@ -104,7 +105,6 @@
     version: string;
     _id: string;
     id: string;
-    'constituent-vnfd': CONSTITUENTVNFD[];
     vendor: string;
     vdur: string[];
     'connection-point': CONNECTIONPOINT[];
@@ -179,6 +179,29 @@
     state?: string;
     memberIndex?: DF[];
     nsConfig?: object;
+    adminDetails?: object;
+    vnfID?: string[];
+    nsd?: NSD;
+    operationParams?: OPERATIONPARAMS;
+    'nsd-id': string;
+}
+
+/** Interface for the operationparams */
+export interface OPERATIONPARAMS{
+    scaleType?: string;
+    scaleVnfData?: SCALEVNFDATA;
+}
+
+/** Interface for the scaleVnfData */
+export interface SCALEVNFDATA{
+    scaleVnfType?: string;
+    scaleByStepData?: SCALEBYSTEPDATA;
+}
+
+/** Interface for the scaleByStepData */
+export interface SCALEBYSTEPDATA{
+    'scaling-group-descriptor'?: string;
+    'member-vnf-index'?: string;
 }
 
 /** Interface for the nsInfo */
diff --git a/src/models/VNFDModel.ts b/src/models/VNFDModel.ts
index 4f76f7c..7029ace 100644
--- a/src/models/VNFDModel.ts
+++ b/src/models/VNFDModel.ts
@@ -83,6 +83,7 @@
     'instantiation-level'?: INSTANTIATIONLEVEL[];
     'vdu-profile'?: VDUPROFILE[];
     'vnf-configuration-id'?: string;
+    'scaling-aspect'?: SCALING[];
 }
 /** Interface for INSTANTIATIONLEVEL */
 export interface INSTANTIATIONLEVEL {
@@ -103,6 +104,31 @@
     'vdu-configuration-id'?: string;
     'vdu-configuration'?: VDUCONFIG;
 }
+/** Interface for SCALING */
+export interface SCALING {
+    'aspect-delta-details'?: object;
+    id: string;
+    name?: string;
+    'max-scale-level'?: number;
+    'scaling-policy'?: SCALINGPOLICY[];
+}
+/** Interface for SCALINGPOLICY */
+export interface SCALINGPOLICY {
+    'cooldown-time': number;
+    name?: string;
+    'scaling-criteria': SCALINGCRITERIA[];
+    'scaling-type'?: string;
+    'threshold-time'?: number;
+}
+/** Interface for SCALINGCRITERIA */
+export interface SCALINGCRITERIA {
+    name?: string;
+    'scale-in-relational-operation': string;
+    'scale-in-threshold'?: string;
+    'scale-out-relational-operation'?: string;
+    'scale-out-threshold'?: string;
+    'vnf-monitoring-param-ref'?: string;
+}
 /** Interface for VDUCONFIG */
 export interface VDUCONFIG {
     id: string;