Feature 10912, 10916: NS Update

	*Added NG-UI support to remove VNF and change VNF in NS update
	*In NS Instances page. Click "Ns Update" in the actions menu.
        *Then a new pop-up page will opened.
        *In the popup there will be drop-down containing Update Type with 'CHANGE_VNFPKG' & 'REMOVE_VNFPKG', membervnfIndex and text field Vnfd Id.
        *When the fields are selected then Click Apply button.
	*For CHANGE_VNFPKG type, the software-version will be checked whether matching or not and corresponding popup will be shown.
        *The pop-up window is closed and the page is directed to "History of operations" page

Change-Id: I135dda039a381b1faa62baa263543e1f210384f7
Signed-off-by: SANDHYA.JS <sandhya.j@tataelxsi.co.in>
diff --git a/src/app/AppModule.ts b/src/app/AppModule.ts
index 06d1004..cc9af15 100644
--- a/src/app/AppModule.ts
+++ b/src/app/AppModule.ts
@@ -65,6 +65,7 @@
 import { NetslicePackagesActionComponent } from 'NetslicePackagesAction';
 import { NSInstancesActionComponent } from 'NSInstancesActionComponent';
 import { NsPackagesActionComponent } from 'NsPackagesAction';
+import { NsUpdateComponent } from 'NsUpdateComponent';
 import { PageNotFoundComponent } from 'PageNotFound';
 import { PDUInstancesActionComponent } from 'PDUInstancesActionComponent';
 import { ProjectLinkComponent } from 'ProjectLinkComponent';
@@ -81,6 +82,7 @@
 import { VNFInstancesActionComponent } from 'VNFInstancesActionComponent';
 import { VNFLinkComponent } from 'VNFLinkComponent';
 import { VNFPackagesActionComponent } from 'VNFPackagesAction';
+import { WarningComponent } from 'WarningComponent';
 import { WIMAccountsActionComponent } from 'WIMAccountsAction';
 
 /**
@@ -129,7 +131,9 @@
         GoToTopDirective,
         ScalingComponent,
         ChangePasswordComponent,
-        VmMigrationComponent
+        VmMigrationComponent,
+        NsUpdateComponent,
+        WarningComponent
     ],
     imports: [
         NotifierModule.withConfig(customNotifierOptions),
@@ -204,7 +208,9 @@
         SwitchProjectComponent,
         ScalingComponent,
         ChangePasswordComponent,
-        VmMigrationComponent
+        VmMigrationComponent,
+        NsUpdateComponent,
+        WarningComponent
     ]
 })
 
diff --git a/src/app/utilities/ns-instances-action/NSInstancesActionComponent.html b/src/app/utilities/ns-instances-action/NSInstancesActionComponent.html
index df5bbd7..92e462f 100644
--- a/src/app/utilities/ns-instances-action/NSInstancesActionComponent.html
+++ b/src/app/utilities/ns-instances-action/NSInstancesActionComponent.html
@@ -47,6 +47,10 @@
                 [disabled]="operationalStatus === 'failed' || configStatus === 'failed'" ngbTooltip="{{'VMMIGRATION' | translate}}">
                 <i class="fas fa-angle-double-left"></i> {{'VMMIGRATION' | translate}}
             </button>
+            <button type="button" class="btn btn-primary dropdown-item" (click)="openNsUpdate()" placement="left" data-container="body"
+                [disabled]="operationalStatus === 'failed' || configStatus === 'failed'" ngbTooltip="{{'NSUPDATE' | translate}}">
+                <i class="fas fa-arrow-alt-circle-up"></i> {{'NSUPDATE' | translate}}
+            </button>
             <button type="button" class="btn btn-primary dropdown-item" (click)="historyOfOperations()" placement="left" container="body" ngbTooltip="{{'HISTORYOFOPERATIONS' | translate}}">
                 <i class="fas fa-history"></i> {{'HISTORYOFOPERATIONS' | translate}}
             </button>
diff --git a/src/app/utilities/ns-instances-action/NSInstancesActionComponent.ts b/src/app/utilities/ns-instances-action/NSInstancesActionComponent.ts
index fb52423..3735df7 100644
--- a/src/app/utilities/ns-instances-action/NSInstancesActionComponent.ts
+++ b/src/app/utilities/ns-instances-action/NSInstancesActionComponent.ts
@@ -29,6 +29,7 @@
 import { NSDDetails } from 'NSDModel';
 import { NSDInstanceData } from 'NSInstanceModel';
 import { NSPrimitiveComponent } from 'NSPrimitiveComponent';
+import { NsUpdateComponent } from 'NsUpdateComponent';
 import { RestService } from 'RestService';
 import { forkJoin, Observable } from 'rxjs';
 import { ScalingComponent } from 'ScalingComponent';
@@ -270,6 +271,19 @@
     }).catch();
   }
 
+  /** To open the Ns Update pop-up */
+  public openNsUpdate(): void {
+    const modalRef: NgbModalRef = this.modalService.open(NsUpdateComponent, { backdrop: 'static' });
+    modalRef.componentInstance.params = {
+      id: this.instanceID
+    };
+    modalRef.result.then((result: MODALCLOSERESPONSEDATA): void => {
+      if (result) {
+        this.sharedService.callData();
+      }
+    }).catch();
+  }
+
   /**
    * Check any changes in the child component @public
    */
diff --git a/src/app/utilities/ns-update/NsUpdateComponent.html b/src/app/utilities/ns-update/NsUpdateComponent.html
new file mode 100644
index 0000000..e3058d6
--- /dev/null
+++ b/src/app/utilities/ns-update/NsUpdateComponent.html
@@ -0,0 +1,68 @@
+<!--
+Copyright 2020 TATA ELXSI
+
+Licensed under the Apache License, Version 2.0 (the 'License');
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+-->
+<div class="modal-header">
+    <h4 class="modal-title" id="modal-basic-title"> {{'NSUPDATE' | translate}} </h4>
+    <button class="button-xs" type="button" class="close" aria-label="Close" (click)="activeModal.close()">
+        <i class="fas fa-times-circle text-danger"></i>
+    </button>
+</div>
+<form [formGroup]="nsUpdateForm" (ngSubmit)="triggerNsUpdate()" autocomplete="off">
+    <div class="modal-body">
+        <div class="form-group row">
+            <label class="col-sm-12 col-form-label mandatory-label"
+                [ngClass]="{'text-danger': nsUpdateForm.invalid === true && submitted === true}">
+                {{'MANDATORYCHECK' | translate}}
+            </label>
+            <div class="col-sm-6">
+                <label for="updateType"> {{'UPDATETYPE' | translate}} *</label>
+            </div>
+            <div class="col-sm-6">
+                <ng-select formControlName="updateType" [clearable]="false" placeholder="{{'SELECT' | translate}}"
+                    [items]="updateTypeList" bindLabel="title" bindValue="value" (change)="terminateVNF($event.value)"
+                    [ngClass]="{ 'is-invalid': submitted && f.updateType.errors }"></ng-select>
+            </div>
+        </div>
+        <div class="form-group row">
+            <div class="col-sm-6">
+                <label for="memberVnfIndex"> {{'MEMBERVNFINDEX' | translate}} *</label>
+            </div>
+            <div class="col-sm-6">
+                <ng-select formControlName="memberVnfIndex" [clearable]="false" [(ngModel)]="memberIndexValue" (change) = 'getSelectedVNF($event.vnfinstanceId)'
+                    placeholder="{{'SELECTMEMBERVNFINDEX' | translate}}" [items]="memberTypes" bindLabel="id"
+                    bindValue="id" [ngClass]="{ 'is-invalid': submitted && f.memberVnfIndex.errors }">
+                </ng-select>
+                <small class="form-text text-muted" *ngIf="selectedvnfId !== ''">vnfd : {{ selectedvnfId }}</small>
+            </div>
+        </div>
+        <div class="form-group row" *ngIf="!vnfdIdShow">
+            <div class="col-sm-6">
+                <label for="vnfdId"> {{'VNFDID' | translate}} *</label>
+            </div>
+            <div class="col-sm-6">
+                <input autocomplete="off" class="form-control" placeholder="{{'VNFDID' | translate}}" type="text"
+                    formControlName="vnfdId" id="computeHost"
+                    [ngClass]="{ 'is-invalid': submitted && f.vnfdId.errors }">
+            </div>
+        </div>
+    </div>
+    <div class="modal-footer">
+        <button type="button" (click)="activeModal.close()" class="btn btn-danger">{{'CANCEL' | translate}}</button>
+        <button type="submit" class="btn btn-primary">{{'APPLY' | translate }}</button>
+    </div>
+</form>
+<app-loader [waitingMessage]="message" *ngIf="isLoadingResults"></app-loader>
\ No newline at end of file
diff --git a/src/app/utilities/ns-update/NsUpdateComponent.scss b/src/app/utilities/ns-update/NsUpdateComponent.scss
new file mode 100644
index 0000000..c55461a
--- /dev/null
+++ b/src/app/utilities/ns-update/NsUpdateComponent.scss
@@ -0,0 +1,17 @@
+/*
+ Copyright 2020 TATA ELXSI
+
+ Licensed under the Apache License, Version 2.0 (the 'License');
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+*/
\ No newline at end of file
diff --git a/src/app/utilities/ns-update/NsUpdateComponent.ts b/src/app/utilities/ns-update/NsUpdateComponent.ts
new file mode 100644
index 0000000..80ddbb4
--- /dev/null
+++ b/src/app/utilities/ns-update/NsUpdateComponent.ts
@@ -0,0 +1,342 @@
+/*
+ Copyright 2020 TATA ELXSI
+
+ Licensed under the Apache License, Version 2.0 (the 'License');
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+*/
+/**
+ * @file Ns Update Component
+ */
+import { HttpHeaders } from '@angular/common/http';
+import { Component, Injector, Input, OnInit } from '@angular/core';
+import { AbstractControl, FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { Router } from '@angular/router';
+import { NgbActiveModal, NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap';
+import { TranslateService } from '@ngx-translate/core';
+import { APIURLHEADER, CONFIGCONSTANT, ERRORDATA, MODALCLOSERESPONSEDATA, URLPARAMS } from 'CommonModel';
+import { environment } from 'environment';
+import { NSUPDATE, TERMINATEVNF } from 'NSInstanceModel';
+import { RestService } from 'RestService';
+import { SharedService } from 'SharedService';
+import { isNullOrUndefined } from 'util';
+import { VNFD } from 'VNFDModel';
+import { VNFInstanceDetails } from 'VNFInstanceModel';
+import { WarningComponent } from 'WarningComponent';
+
+/**
+ * Creating component
+ * @Component takes NsUpdateComponent.html as template url
+ */
+@Component({
+    selector: 'app-ns-update',
+    templateUrl: './NsUpdateComponent.html',
+    styleUrls: ['./NsUpdateComponent.scss']
+})
+export class NsUpdateComponent implements OnInit {
+    /** To inject services @public */
+    public injector: Injector;
+    /** Instance for active modal service @public */
+    public activeModal: NgbActiveModal;
+    /** Check the loading results @public */
+    public isLoadingResults: Boolean = false;
+    /** Give the message for the loading @public */
+    public message: string = 'PLEASEWAIT';
+    /** FormGroup instance added to the form @ html @public */
+    public nsUpdateForm: FormGroup;
+    /** Items for the member types @public */
+    public memberTypes: {}[];
+    /** Contains objects that is used to hold types of primitive @public */
+    public updateTypeList: {}[] = [];
+    /** Form valid on submit trigger @public */
+    public submitted: boolean = false;
+    /** Give the update type @public */
+    public terminateVnf: string;
+    /** Model value used to hold selected MemberVNFIndex @public */
+    public memberIndexValue: string;
+    /** Form Check vnfdId Section @public */
+    public vnfdIdShow: boolean = false;
+    /** Contains MemberVNFIndex values @public */
+    public memberVnfIndex: {}[] = [];
+    /** Array holds VNFR Data filtered with nsr ID @public */
+    public nsIdFilteredData: {}[] = [];
+    /** Contains vnfdId value @public */
+    public vnfdId: string;
+    /** Contains vnfId value of the selected MemberVnfIndex @public */
+    public vnfID: string;
+    /** Contains version of the selected MemberVnfIndex @public */
+    public version: string;
+    /** Contains version of the vnfId @public */
+    public vnfversion: string;
+    /** Contains vnfInstanceId of the selected MemberVnfIndex  @public */
+    public instanceId: string;
+    /** Selected VNFInstanceId @public */
+    public selectedvnfId: string = '';
+    /** Input contains component objects @private */
+    @Input() private params: URLPARAMS;
+    /** FormBuilder instance added to the formBuilder @private */
+    private formBuilder: FormBuilder;
+    /** Contains tranlsate instance @private */
+    private translateService: TranslateService;
+    /** Instance of the rest service @private */
+    private restService: RestService;
+    /** Controls the header form @private */
+    private headers: HttpHeaders;
+    /** Contains all methods related to shared @private */
+    private sharedService: SharedService;
+    /** Holds the instance of AuthService class of type AuthService @private */
+    private router: Router;
+    /** Instance of the modal service @private */
+    private modalService: NgbModal;
+    constructor(injector: Injector) {
+        this.injector = injector;
+        this.restService = this.injector.get(RestService);
+        this.activeModal = this.injector.get(NgbActiveModal);
+        this.formBuilder = this.injector.get(FormBuilder);
+        this.sharedService = this.injector.get(SharedService);
+        this.translateService = this.injector.get(TranslateService);
+        this.router = this.injector.get(Router);
+        this.modalService = this.injector.get(NgbModal);
+        this.updateTypeList = [
+            {
+                title: this.translateService.instant('VNFPKGCHANGE'),
+                value: 'CHANGE_VNFPKG'
+            },
+            {
+                title: this.translateService.instant('REMOVEVNF'),
+                value: 'REMOVE_VNF'
+            }
+        ];
+    }
+    /** convenience getter for easy access to form fields */
+    get f(): FormGroup['controls'] { return this.nsUpdateForm.controls; }
+    /**
+     * Lifecyle Hooks the trigger before component is instantiate
+     */
+    public ngOnInit(): void {
+        this.initializeForm();
+        this.getMemberVnfIndex();
+        this.headers = new HttpHeaders({
+            'Content-Type': 'application/json',
+            Accept: 'application/json',
+            'Cache-Control': 'no-cache, no-store, must-revalidate, max-age=0'
+        });
+    }
+
+    /** Initialize Ns Update Forms @public */
+    public initializeForm(): void {
+        this.nsUpdateForm = this.formBuilder.group({
+            updateType: [null, [Validators.required]],
+            memberVnfIndex: [null, [Validators.required]],
+            vnfdId: [null, [Validators.required]]
+        });
+    }
+
+    /** Getting MemberVnfIndex using NSDescriptor API @public */
+    public getMemberVnfIndex(): void {
+        const vnfInstanceData: {}[] = [];
+        this.restService.getResource(environment.VNFINSTANCES_URL).subscribe((vnfInstancesData: VNFInstanceDetails[]): void => {
+            vnfInstancesData.forEach((vnfData: VNFInstanceDetails): void => {
+                const vnfDataObj: {} =
+                {
+                    VNFD: vnfData['vnfd-ref'],
+                    VNFInstanceId: vnfData._id,
+                    MemberIndex: vnfData['member-vnf-index-ref'],
+                    NS: vnfData['nsr-id-ref'],
+                    VNFID: vnfData['vnfd-id']
+                };
+                vnfInstanceData.push(vnfDataObj);
+            });
+            const nsId: string = 'NS';
+            this.nsIdFilteredData = vnfInstanceData.filter((vnfdData: {}[]): boolean => vnfdData[nsId] === this.params.id);
+            this.nsIdFilteredData.forEach((resVNF: {}[]): void => {
+                const memberIndex: string = 'MemberIndex';
+                const vnfinstanceID: string = 'VNFInstanceId';
+                const assignMemberIndex: {} = {
+                    id: resVNF[memberIndex],
+                    vnfinstanceId: resVNF[vnfinstanceID]
+                };
+                this.memberVnfIndex.push(assignMemberIndex);
+            });
+            this.memberTypes = this.memberVnfIndex;
+            this.isLoadingResults = false;
+        }, (error: ERRORDATA): void => {
+            this.restService.handleError(error, 'get');
+            this.isLoadingResults = false;
+        });
+    }
+
+    /**
+     *  Fetching the VNFR Information filtered with MemberVnfIndex
+     *  Get the selected VNF Instance ID
+     */
+    public getSelectedVNF(id: string): void {
+        this.instanceId = id;
+        let memberIndexFilteredData: {}[] = [];
+        const memberIndex: string = 'MemberIndex';
+        memberIndexFilteredData = this.nsIdFilteredData.filter((vnfdData: {}[]): boolean =>
+            vnfdData[memberIndex] === this.memberIndexValue);
+        const vnfId: string = 'VNFID';
+        const selectedvnfId: string = 'VNFD';
+        for (const data of memberIndexFilteredData) {
+            this.vnfID = data[vnfId];
+            this.selectedvnfId = data[selectedvnfId];
+        }
+    }
+
+    /** Trigger NsUpdate on submit */
+    public triggerNsUpdate(): void {
+        this.submitted = true;
+        this.sharedService.cleanForm(this.nsUpdateForm);
+        if (this.nsUpdateForm.invalid) { return; } // Proceed, onces form is valid
+        this.vnfdId = this.nsUpdateForm.value.vnfdId;
+        this.checkUpdateType();
+    }
+
+    /** Ns Update on submit */
+    public onSubmit(): void {
+        if (this.terminateVnf === 'REMOVE_VNF') {
+            const nsUpdateTerminatePayload: TERMINATEVNF = {
+                lcmOperationType: 'update',
+                updateType: this.nsUpdateForm.value.updateType,
+                nsInstanceId: this.params.id,
+                removeVnfInstanceId: this.instanceId
+            };
+            this.nsUpdateInitialization(nsUpdateTerminatePayload);
+        } else {
+            const nsUpdatePayload: NSUPDATE = {
+                lcmOperationType: 'update',
+                updateType: this.nsUpdateForm.value.updateType,
+                nsInstanceId: this.params.id,
+                changeVnfPackageData: {
+                    vnfInstanceId: this.instanceId,
+                    vnfdId: this.nsUpdateForm.value.vnfdId
+                }
+            };
+            this.nsUpdateInitialization(nsUpdatePayload);
+        }
+    }
+
+    /**
+     *  Open Modal based on selected NS-UPDATE Type
+     */
+    public checkUpdateType(): void {
+        this.isLoadingResults = true;
+        if (this.nsUpdateForm.value.updateType === 'CHANGE_VNFPKG') {
+            this.checkVersion();
+        } else {
+            const modalRef: NgbModalRef = this.modalService.open(WarningComponent, { backdrop: 'static' });
+            modalRef.componentInstance.heading = this.translateService.instant('TERMINATEVNF');
+            modalRef.componentInstance.confirmationMessage = this.translateService.instant('TERMINATEVNFCONTENT');
+            modalRef.componentInstance.submitMessage = this.translateService.instant('TERMINATEVNF');
+            modalRef.result.then((result: MODALCLOSERESPONSEDATA): void => {
+                if (result.message === CONFIGCONSTANT.done) {
+                    this.onSubmit();
+                }
+            }).catch();
+        }
+        this.isLoadingResults = false;
+    }
+
+    /** To check the versions are matching or not for 'CHANGE_VNFPKG' type */
+    public checkVersion(): void {
+        this.isLoadingResults = true;
+        const vnfDetails: {}[] = [];
+        this.restService.getResource(environment.VNFPACKAGESCONTENT_URL + '/' + this.vnfdId).subscribe((vnfData: VNFD[]): void => {
+            if (!isNullOrUndefined(vnfData['software-version'])) {
+                this.version = vnfData['software-version'];
+            }
+            this.restService.getResource(environment.VNFPACKAGESCONTENT_URL).subscribe((vnfDetail: VNFD[]): void => {
+                vnfDetail.forEach((vnfDatas: VNFD): void => {
+                    const vnfDataObj: {} =
+                    {
+                        VNFID: vnfDatas._id,
+                        version: vnfDatas['software-version']
+                    };
+                    vnfDetails.push(vnfDataObj);
+                });
+                let vnfIdFilteredData: {}[] = [];
+                const vnfID: string = 'VNFID';
+                const version: string = 'version';
+                vnfIdFilteredData = vnfDetails.filter((vnfdData: {}[]): boolean => vnfdData[vnfID] === this.vnfID);
+                for (const data of vnfIdFilteredData) {
+                    this.vnfversion = data[version];
+                }
+                if (this.version === this.vnfversion) {
+                    const modalRef: NgbModalRef = this.modalService.open(WarningComponent, { backdrop: 'static' });
+                    modalRef.componentInstance.heading = this.translateService.instant('UPDATEPOLICIES');
+                    modalRef.componentInstance.confirmationMessage = this.translateService.instant('UPDATEPOLICIESCONTENT');
+                    modalRef.componentInstance.submitMessage = this.translateService.instant('UPDATEPOLICIES');
+                    modalRef.result.then((result: MODALCLOSERESPONSEDATA): void => {
+                        if (result.message === CONFIGCONSTANT.done) {
+                            this.onSubmit();
+                        }
+                    }).catch();
+                } else {
+                    const modalRef: NgbModalRef = this.modalService.open(WarningComponent, { backdrop: 'static' });
+                    modalRef.componentInstance.heading = this.translateService.instant('REDEPLOY');
+                    modalRef.componentInstance.confirmationMessage = this.translateService.instant('REDEPLOYCONTENT');
+                    modalRef.componentInstance.submitMessage = this.translateService.instant('REDEPLOY');
+                    modalRef.result.then((result: MODALCLOSERESPONSEDATA): void => {
+                        if (result.message === CONFIGCONSTANT.done) {
+                            this.onSubmit();
+                        }
+                    }).catch();
+                }
+            }, (error: ERRORDATA): void => {
+                this.restService.handleError(error, 'get');
+                this.isLoadingResults = false;
+            });
+            this.isLoadingResults = false;
+        }, (error: ERRORDATA): void => {
+            this.restService.handleError(error, 'get');
+            this.isLoadingResults = false;
+        });
+    }
+
+    /** Initialize the Ns Update @public */
+    public nsUpdateInitialization(nsUpdatePayload: object): void {
+        this.isLoadingResults = true;
+        const apiURLHeader: APIURLHEADER = {
+            url: environment.NSDINSTANCES_URL + '/' + this.params.id + '/update',
+            httpOptions: { headers: this.headers }
+        };
+        const modalData: MODALCLOSERESPONSEDATA = {
+            message: 'Done'
+        };
+        this.restService.postResource(apiURLHeader, nsUpdatePayload).subscribe((result: {}): void => {
+            this.activeModal.close(modalData);
+            this.router.navigate(['/instances/ns/history-operations/' + this.params.id]).catch();
+        }, (error: ERRORDATA): void => {
+            this.restService.handleError(error, 'post');
+            this.isLoadingResults = false;
+        });
+    }
+
+    /** To enable or disable vnfdId field @public */
+    public terminateVNF(value: string): void {
+        this.terminateVnf = value;
+        if (this.terminateVnf === 'REMOVE_VNF') {
+            this.vnfdIdShow = true;
+            this.getFormControl('vnfdId').disable();
+        } else {
+            this.vnfdIdShow = false;
+            this.getFormControl('vnfdId').enable();
+        }
+    }
+
+    /** Used to get the AbstractControl of controlName passed @private */
+    private getFormControl(controlName: string): AbstractControl {
+        return this.nsUpdateForm.controls[controlName];
+    }
+}
diff --git a/src/app/utilities/warning/WarningComponent.html b/src/app/utilities/warning/WarningComponent.html
new file mode 100644
index 0000000..9be2656
--- /dev/null
+++ b/src/app/utilities/warning/WarningComponent.html
@@ -0,0 +1,33 @@
+<!--
+Copyright 2020 TATA ELXSI
+
+Licensed under the Apache License, Version 2.0 (the 'License');
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+-->
+<div class="modal-header">
+    <h4 class="modal-title" id="modal-basic-title">
+        {{heading}}
+    </h4>
+    <button class="button-xs" type="button" class="close" (click)="closeModal('close')">
+        <i class="fas fa-times-circle text-danger"></i>
+    </button>
+</div>
+<div class="modal-body">
+    <span>{{confirmationMessage}} ?</span>
+</div>
+<div class="modal-footer">
+    <button (click)="closeModal('close')" class="btn btn-danger">{{'CANCEL' | translate }}</button>
+    <button (click)="closeModal('done')" class="btn btn-success">{{submitMessage}}</button>
+</div>
+<app-loader [waitingMessage]="message" *ngIf="isLoad"></app-loader>
\ No newline at end of file
diff --git a/src/app/utilities/warning/WarningComponent.scss b/src/app/utilities/warning/WarningComponent.scss
new file mode 100644
index 0000000..c55461a
--- /dev/null
+++ b/src/app/utilities/warning/WarningComponent.scss
@@ -0,0 +1,17 @@
+/*
+ Copyright 2020 TATA ELXSI
+
+ Licensed under the Apache License, Version 2.0 (the 'License');
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+*/
\ No newline at end of file
diff --git a/src/app/utilities/warning/WarningComponent.ts b/src/app/utilities/warning/WarningComponent.ts
new file mode 100644
index 0000000..0ccb888
--- /dev/null
+++ b/src/app/utilities/warning/WarningComponent.ts
@@ -0,0 +1,74 @@
+/*
+ Copyright 2020 TATA ELXSI
+
+ Licensed under the Apache License, Version 2.0 (the 'License');
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ Author: SANDHYA JS (sandhya.j@tataelxsi.co.in)
+*/
+/**
+ * @file WarningConfiguration Model
+ */
+import { Component, Injector, Input } from '@angular/core';
+import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';
+/**
+ * Creating component
+ * @Component takes WarningComponent.html as template url
+ */
+@Component({
+    selector: 'app-warning',
+    templateUrl: './WarningComponent.html',
+    styleUrls: ['./WarningComponent.scss']
+})
+/** Exporting a class @exports WarningComponent */
+export class WarningComponent {
+    /** To inject services @public */
+    public injector: Injector;
+
+    /** Instance for active modal service @public */
+    public activeModal: NgbActiveModal;
+
+    /** Check the loading results @public */
+    public isLoad: Boolean = false;
+
+    /** Contains title data @public */
+    @Input()
+    public heading: string;
+
+    /** Contains body data @public */
+    @Input()
+    public confirmationMessage: string;
+
+    /** Contains footer data @public */
+    @Input()
+    public submitMessage: string;
+
+    /** Give the message for the loading @public */
+    public message: string = 'PLEASEWAIT';
+
+    constructor(injector: Injector) {
+        this.injector = injector;
+        this.activeModal = this.injector.get(NgbActiveModal);
+    }
+
+    /**
+     * Lifecyle Hooks the trigger before component is instantiate
+     */
+    public ngOnInit(): void {
+        //empty
+    }
+
+    /** Close the modal  @public */
+    public closeModal(getMessage: string): void {
+        this.activeModal.close({ message: getMessage });
+    }
+}