From 06f53244384e546cc15750f6d050a98a752a0ade Mon Sep 17 00:00:00 2001 From: Einat Vinouze Date: Mon, 16 Mar 2020 19:08:22 +0200 Subject: allow LOB multi-selection for network Issue-ID: VID-788 Change-Id: I03674ea0c04567291ba647c76b7c88bc11a7cf0e Signed-off-by: Einat Vinouze --- ...setMSOCreateNetworkALaCarteServiceCypress2.java | 10 ++++-- .../test/test/NewServiceInstanceTest.java | 4 ++- .../api/AsyncInstantiationALaCarteApiTest3.java | 2 +- .../vidRequestDelete1Create1Network.json | 2 +- .../cypress/integration/iFrames/ala-carte.e2e.ts | 12 +++---- .../integration/iFrames/drawingBoard.e2e.ts | 6 ++-- .../iFrames/instantiation-templates.e2e.ts | 4 +-- .../integration/iFrames/network.popup.e2e.ts | 13 ++++---- .../cypress/integration/iFrames/vnf.popup.e2e.ts | 2 +- .../jsonBuilders/mocks/jsons/flags.cypress.json | 3 +- .../cypress/support/steps/fill.network.step.ts | 11 ++++--- .../cypress/support/steps/fill.vnf.popup.step.ts | 2 +- .../steps/genericForm/genericFormAction.steps.ts | 37 +++++++++++++++++++--- .../networkGenerator/network.control.generator.ts | 4 +-- .../sharedControlles/shared.controllers.service.ts | 6 +++- 15 files changed, 80 insertions(+), 38 deletions(-) diff --git a/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOCreateNetworkALaCarteServiceCypress2.java b/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOCreateNetworkALaCarteServiceCypress2.java index b7f629c8a..2df43b82a 100644 --- a/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOCreateNetworkALaCarteServiceCypress2.java +++ b/vid-automation/src/main/java/org/onap/simulator/presetGenerator/presets/mso/PresetMSOCreateNetworkALaCarteServiceCypress2.java @@ -6,21 +6,25 @@ public class PresetMSOCreateNetworkALaCarteServiceCypress2 extends PresetMSOBase private String serviceModelName; private String serviceModelVersionId; private String platformName; + private String lineOfBusinessName; + public PresetMSOCreateNetworkALaCarteServiceCypress2(String overrideRequestId, String serviceInstanceId, String networkName) { this(overrideRequestId, serviceInstanceId, networkName, "ComplexService", "6e59c5de-f052-46fa-aa7e-2fca9d674c44", - "xxx1"); + "xxx1", "zzz1"); } public PresetMSOCreateNetworkALaCarteServiceCypress2(String overrideRequestId, String serviceInstanceId, - String networkName, String serviceModelName, String serviceModelVersionId, String platformName) { + String networkName, String serviceModelName, String serviceModelVersionId, String platformName, + String lineOfBusinessName) { super(overrideRequestId); this.serviceInstanceId = serviceInstanceId; this.networkName = networkName; this.serviceModelName = serviceModelName; this.serviceModelVersionId = serviceModelVersionId; this.platformName = platformName; + this.lineOfBusinessName = lineOfBusinessName; } @Override @@ -42,7 +46,7 @@ public class PresetMSOCreateNetworkALaCarteServiceCypress2 extends PresetMSOBase "\"source\":\"VID\"," + "\"suppressRollback\":false," + "\"requestorId\":\"us16807000\"}," + - "\"lineOfBusiness\":{\"lineOfBusinessName\":\"zzz1\"}," + + "\"lineOfBusiness\":{\"lineOfBusinessName\":\"" + lineOfBusinessName + "\"}," + "\"cloudConfiguration\":" + "{\"lcpCloudRegionId\":\"hvf6\"," + addCloudOwnerIfNeeded() + diff --git a/vid-automation/src/main/java/vid/automation/test/test/NewServiceInstanceTest.java b/vid-automation/src/main/java/vid/automation/test/test/NewServiceInstanceTest.java index 99e824086..7ce350060 100644 --- a/vid-automation/src/main/java/vid/automation/test/test/NewServiceInstanceTest.java +++ b/vid-automation/src/main/java/vid/automation/test/test/NewServiceInstanceTest.java @@ -1205,9 +1205,11 @@ public class NewServiceInstanceTest extends ModernUITestBase { if(!isNetwork){ SelectOption.byTestIdAndVisibleText("TYLER SILVIA", Constants.ViewEdit.PRODUCT_FAMILY_SELECT_TESTS_ID); browseASDCPage.selectProductFamily("e433710f-9217-458d-a79d-1c7aff376d89"); + browseASDCPage.selectLineOfBusiness("ONAP"); + } else { + SelectOption.selectOptionsFromMultiselectById("multi-lineOfBusiness",ImmutableList.of("ONAP")); } - browseASDCPage.selectLineOfBusiness("ONAP"); assertSetButtonEnabled(VNF_SET_BUTTON_TEST_ID); browseASDCPage.setLegacyRegion("some legacy region"); diff --git a/vid-automation/src/test/java/org/onap/vid/api/AsyncInstantiationALaCarteApiTest3.java b/vid-automation/src/test/java/org/onap/vid/api/AsyncInstantiationALaCarteApiTest3.java index 70ded1c09..07b81a46c 100644 --- a/vid-automation/src/test/java/org/onap/vid/api/AsyncInstantiationALaCarteApiTest3.java +++ b/vid-automation/src/test/java/org/onap/vid/api/AsyncInstantiationALaCarteApiTest3.java @@ -379,7 +379,7 @@ public class AsyncInstantiationALaCarteApiTest3 extends AsyncInstantiationBase { new PresetMSOOrchestrationRequestGet(COMPLETE, deleteRequestId), new PresetMSOCreateNetworkALaCarteServiceCypress2(createRequestId, serviceInstanceId, "ExtVL", "action-data", - "6b528779-44a3-4472-bdff-9cd15ec93450", "xxx1,platform"), + "6b528779-44a3-4472-bdff-9cd15ec93450", "xxx1,platform", "zzz1,ONAP"), new PresetMSOOrchestrationRequestGet(COMPLETE, createRequestId), PresetAAIGetCloudOwnersByCloudRegionId.PRESET_MTN6_TO_ATT_AIC ), RegistrationStrategy.CLEAR_THEN_SET); diff --git a/vid-automation/src/test/resources/asyncInstantiation/vidRequestDelete1Create1Network.json b/vid-automation/src/test/resources/asyncInstantiation/vidRequestDelete1Create1Network.json index 114565ee3..af7ddd27c 100644 --- a/vid-automation/src/test/resources/asyncInstantiation/vidRequestDelete1Create1Network.json +++ b/vid-automation/src/test/resources/asyncInstantiation/vidRequestDelete1Create1Network.json @@ -65,7 +65,7 @@ "lcpCloudRegionId":"hvf6", "tenantId":"229bcdc6eaeb4ca59d55221141d01f8e", "platformName":"xxx1,platform" , - "lineOfBusiness":"zzz1", + "lineOfBusiness":"zzz1,ONAP", "instanceParams":[ { diff --git a/vid-webpack-master/cypress/integration/iFrames/ala-carte.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/ala-carte.e2e.ts index 4988ec8e8..4fa3ae600 100644 --- a/vid-webpack-master/cypress/integration/iFrames/ala-carte.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/ala-carte.e2e.ts @@ -136,7 +136,7 @@ describe('A la carte', function () { cy.selectDropdownOptionByText('tenant', 'USP-SIP-IC-24335-T-01'); cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); - cy.selectPlatformValue('xxx1'); + cy.selectPlatformValue(`xxx1`); cy.getElementByDataTestsId('form-set').click({force: true}).then(() => { @@ -144,7 +144,7 @@ describe('A la carte', function () { cy.getElementByDataTestsId(vnfMenuBtnDataTestId).click({force: true}).then(() => { cy.getElementByDataTestsId('context-menu-edit').click({force: true}); - cy.selectPlatformValue('platform'); + cy.selectPlatformValue(`platform`); cy.getElementByDataTestsId('form-set').click({force: true}).then(() => { cy.getReduxState().then((state) => { @@ -195,11 +195,11 @@ describe('A la carte', function () { cy.openIframe('app/ui/#/servicePlanning?serviceModelId=2f80c596-27e5-4ca9-b5bb-e03a7fd4c0fd'); cy.getElementByDataTestsId("node-ExtVL 0-add-btn").click({force: true}); - cy.selectPlatformValue("xxx1"); + cy.selectPlatformValue(`xxx1`); cy.selectDropdownOptionByText("lcpRegion", "AAIAIC25"); cy.selectDropdownOptionByText("tenant", "USP-SIP-IC-24335-T-01"); cy.selectDropdownOptionByText("productFamily", "ERICA"); - cy.selectDropdownOptionByText("lineOfBusiness", "zzz1"); + cy.selectMultiselectValue("multi-lineOfBusiness", "multi-lineOfBusiness-zzz1"); cy.typeToInput("lcpRegionText", "lcpRegionText"); cy.getElementByDataTestsId('form-set').click({force: true}).then(() => { @@ -229,7 +229,7 @@ describe('A la carte', function () { cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); cy.selectDropdownOptionByText('lcpRegion', 'foo-name'); cy.selectDropdownOptionByText('tenant', 'tenantID'); - cy.selectPlatformValue('xxx1'); + cy.selectPlatformValue(`xxx1`); cy.getElementByDataTestsId('form-set').click({force: true}).then(() => { const vnfMenuBtnDataTestId = 'node-69e09f68-8b63-4cc9-b9ff-860960b5db09-2017-488_PASQUALE-vPE 0-menu-btn'; @@ -266,7 +266,7 @@ describe('A la carte', function () { cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2'); cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); - cy.selectPlatformValue('xxx1'); + cy.selectPlatformValue(`xxx1`); cy.getElementByDataTestsId('form-set').click({force: true}).then(() => { const vnfName = '2017-488_PASQUALE-vPE 0'; let vfModulesNames: Array = [ diff --git a/vid-webpack-master/cypress/integration/iFrames/drawingBoard.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/drawingBoard.e2e.ts index 88ad8e8a2..87bbb5b9d 100644 --- a/vid-webpack-master/cypress/integration/iFrames/drawingBoard.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/drawingBoard.e2e.ts @@ -377,7 +377,7 @@ describe('Drawing board', function () { cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-testalexandria'); cy.selectDropdownOptionByText('lineOfBusiness', 'ONAP'); - cy.selectPlatformValue('platform'); + cy.selectPlatformValue(`platform`); cy.genericFormSubmitForm(); cy.getElementByDataTestsId('node-afacccf6-397d-45d6-b5ae-94c39734b168-2017-388_PASQUALE-vPE 0').contains(''); @@ -397,8 +397,8 @@ describe('Drawing board', function () { cy.selectDropdownOptionByText('productFamily', 'ERICA'); cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-testalexandria'); - cy.selectDropdownOptionByText('lineOfBusiness', 'ONAP') - cy.selectPlatformValue('platform'); + cy.selectLobValue("ONAP"); + cy.selectPlatformValue(`platform`); cy.genericFormSubmitForm(); diff --git a/vid-webpack-master/cypress/integration/iFrames/instantiation-templates.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/instantiation-templates.e2e.ts index bb2c01abd..8a68a1393 100644 --- a/vid-webpack-master/cypress/integration/iFrames/instantiation-templates.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/instantiation-templates.e2e.ts @@ -99,7 +99,7 @@ describe('Drawing Board: Instantiation Templates', function () { .getElementByDataTestsId("lcpRegion").should('contain', 'hvf6') .getElementByDataTestsId("lineOfBusiness").should('contain', 'zzz1') .getElementByDataTestsId("rollback").should('contain', 'Rollback') - .checkPlatformValue('xxx1') + cy.checkPlatformValue(`xxx1`) .getElementByDataTestsId("cancelButton").click(); cy.editNode("node-c5b26cc1-a66f-4b69-aa23-6abc7c647c88-vprobe_nc_vnf0..VprobeNcVnf..FE_base_module..module-0") @@ -223,7 +223,7 @@ describe('Drawing Board: Instantiation Templates', function () { // edit vnf cy.editNode("node-21ae311e-432f-4c54-b855-446d0b8ded72-vProbe_NC_VNF 0"); if (testCase.modifySomeValues) { - cy.selectPlatformValue('platform'); + cy.selectPlatformValue(`platform`); cy.selectDropdownOptionByText("tenant", "CESAR-100-D-spjg61909"); } cy.getElementByDataTestsId('form-set').click(); diff --git a/vid-webpack-master/cypress/integration/iFrames/network.popup.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/network.popup.e2e.ts index a17443135..5702d5a0c 100644 --- a/vid-webpack-master/cypress/integration/iFrames/network.popup.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/network.popup.e2e.ts @@ -56,7 +56,7 @@ describe('Network popup', function () { cy.checkIsOptionSelected('productFamily', 'a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb'); cy.checkIsOptionSelected('lcpRegion', 'hvf6'); cy.checkIsOptionSelected('tenant', '229bcdc6eaeb4ca59d55221141d01f8e'); - cy.checkIsOptionSelected('lineOfBusiness', 'zzz1'); + cy.checkLobValue( "zzz1"); cy.checkPlatformValue('xxx1'); //change platform value cy.selectPlatformValue('platform'); @@ -64,9 +64,9 @@ describe('Network popup', function () { cy.getElementByDataTestsId('numberButton').contains('1'); cy.getElementByDataTestsId('node-ddc3f20c-08b5-40fd-af72-c6d14636b986-ExtVL 0-menu-btn').click({force: true}) .getElementByDataTestsId('context-menu-edit').click({force: true}).then(() => { - cy.checkPlatformValue( 'platform'); + cy.checkPlatformValue('platform'); // cancel button should close the dialog - cy.getElementByDataTestsId('cancelButton').click({force: true}).then(() => { + cy.getElementByDataTestsId('cancelButton').click({force: true, multiple: true}).then(() => { // duplicate network cy.getElementByDataTestsId('node-ddc3f20c-08b5-40fd-af72-c6d14636b986-ExtVL 0-menu-btn').click({force: true}) .getElementByDataTestsId('context-menu-duplicate').click({force: true}).then(() => { @@ -129,7 +129,7 @@ describe('Network popup', function () { cy.selectDropdownOptionByText('productFamily', 'Emanuel'); cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2'); - cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); + cy.selectLobValue("zzz1"); cy.selectPlatformValue('xxx1'); cy.getElementByDataTestsId('form-set').should('not.have.attr', 'disabled'); @@ -175,7 +175,7 @@ describe('Network popup', function () { //add one network cy.getElementByDataTestsId('node-ExtVL 0-add-btn').click({force: true}).then(() => { verifyServiceModelNameInModelInfo(); - cy.fillNetworkPopup(true); + cy.fillNetworkPopup(true, true); }); @@ -216,7 +216,8 @@ describe('Network popup', function () { "FLAG_ADVANCED_PORTS_FILTER": true, "FLAG_REGION_ID_FROM_REMOTE": true, "FLAG_ADD_MSO_TESTAPI_FIELD": true, - "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT": true + "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true, + "FLAG_2006_NETWORK_LOB_MULTI_SELECT": true, }, "type": "[FLAGS] Update" }, diff --git a/vid-webpack-master/cypress/integration/iFrames/vnf.popup.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/vnf.popup.e2e.ts index 74ce2a772..3b56ac085 100644 --- a/vid-webpack-master/cypress/integration/iFrames/vnf.popup.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/vnf.popup.e2e.ts @@ -81,7 +81,7 @@ describe('Vnf popup', function () { cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2'); cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); - cy.selectPlatformValue('xxx1'); + cy.selectPlatformValue(`xxx1`); }) }); diff --git a/vid-webpack-master/cypress/support/jsonBuilders/mocks/jsons/flags.cypress.json b/vid-webpack-master/cypress/support/jsonBuilders/mocks/jsons/flags.cypress.json index 148f6b4d5..7c778c86b 100644 --- a/vid-webpack-master/cypress/support/jsonBuilders/mocks/jsons/flags.cypress.json +++ b/vid-webpack-master/cypress/support/jsonBuilders/mocks/jsons/flags.cypress.json @@ -25,5 +25,6 @@ "FLAG_2004_CREATE_ANOTHER_INSTANCE_FROM_TEMPLATE": true, "FLAG_2006_VFM_SDNC_PRELOAD_FILES" : true, "FLAG_2006_VFMODULE_TAKES_TENANT_AND_REGION_FROM_VNF": true, - "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true + "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true, + "FLAG_2006_NETWORK_LOB_MULTI_SELECT" : true } diff --git a/vid-webpack-master/cypress/support/steps/fill.network.step.ts b/vid-webpack-master/cypress/support/steps/fill.network.step.ts index 4ca1796f1..0fa7f6b32 100644 --- a/vid-webpack-master/cypress/support/steps/fill.network.step.ts +++ b/vid-webpack-master/cypress/support/steps/fill.network.step.ts @@ -5,14 +5,17 @@ declare namespace Cypress { } } -function fillNetworkPopup(shouldSelectAdditionalPlatform: boolean = false): Cypress.Chainable { +function fillNetworkPopup(shouldSelectAdditionalPlatform: boolean = false, shouldSelectAdditionalLob: boolean = false): Cypress.Chainable { cy.selectDropdownOptionByText('productFamily', 'Emanuel'); cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2'); - cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); - cy.selectPlatformValue('xxx1'); + cy.selectLobValue("zzz1"); + cy.selectPlatformValue(`xxx1`); if(shouldSelectAdditionalPlatform){ - cy.selectPlatformValue('platform'); + cy.selectPlatformValue(`platform`); + } + if(shouldSelectAdditionalLob){ + cy.selectLobValue("ONAP"); } return cy.getElementByDataTestsId('form-set').click({force : true}).then((done)=>{ return done; diff --git a/vid-webpack-master/cypress/support/steps/fill.vnf.popup.step.ts b/vid-webpack-master/cypress/support/steps/fill.vnf.popup.step.ts index 29166f67d..7c82cf802 100644 --- a/vid-webpack-master/cypress/support/steps/fill.vnf.popup.step.ts +++ b/vid-webpack-master/cypress/support/steps/fill.vnf.popup.step.ts @@ -12,7 +12,7 @@ function FillVnfPopup(): Chainable { cy.selectDropdownOptionByText('lcpRegion', 'hvf6'); cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2'); cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1'); - cy.selectPlatformValue('xxx1'); + cy.selectPlatformValue(`xxx1`); return cy.getElementByDataTestsId('form-set').click({force : true}).then((done)=>{ return done; }); diff --git a/vid-webpack-master/cypress/support/steps/genericForm/genericFormAction.steps.ts b/vid-webpack-master/cypress/support/steps/genericForm/genericFormAction.steps.ts index 115173632..b9c051e54 100644 --- a/vid-webpack-master/cypress/support/steps/genericForm/genericFormAction.steps.ts +++ b/vid-webpack-master/cypress/support/steps/genericForm/genericFormAction.steps.ts @@ -1,20 +1,42 @@ declare namespace Cypress { interface Chainable { genericFormSubmitForm: typeof genericFormSubmitForm + selectMultiselectValue: typeof selectMultiselectValue selectPlatformValue: typeof selectPlatformValue + selectLobValue: typeof selectLobValue + checkMultiSelectValue: typeof checkMultiSelectValue checkPlatformValue: typeof checkPlatformValue + checkLobValue: typeof checkLobValue + } } -function selectPlatformValue(selectOption: string) { - cy.getElementByDataTestsId("multi-selectPlatform").get('.c-btn').click({force: true}); - cy.getElementByDataTestsId(`multi-selectPlatform-${selectOption}`).click(); - cy.getElementByDataTestsId("multi-selectPlatform").get('.c-btn').click({force: true}); +function selectMultiselectValue(dataTestsId: string , selectOptionId: string) { + cy.getElementByDataTestsId(dataTestsId).find('.c-btn').eq(0).click({force: true}) + cy.getElementByDataTestsId(selectOptionId).click(); + cy.getElementByDataTestsId(dataTestsId).find('.c-btn').eq(0).click({force: true}) +} + +function selectPlatformValue(selectOptionId: string) { + selectMultiselectValue("multi-selectPlatform", "multi-selectPlatform-" + selectOptionId) +} + +function selectLobValue(selectOptionId: string) { + selectMultiselectValue("multi-lineOfBusiness", "multi-lineOfBusiness-" + selectOptionId) + } function checkPlatformValue(value: string){ - return cy.getElementByDataTestsId("multi-selectPlatform").should("contain", value) + return checkMultiSelectValue("multi-selectPlatform", value) +} + +function checkLobValue(value: string){ + return checkMultiSelectValue("multi-lineOfBusiness", value) +} + +function checkMultiSelectValue(dataTestsId: string, value: string) { + return cy.getElementByDataTestsId(dataTestsId).should("contain", value) } function genericFormSubmitForm(): Chainable { @@ -23,5 +45,10 @@ function genericFormSubmitForm(): Chainable { Cypress.Commands.add('genericFormSubmitForm', genericFormSubmitForm); +Cypress.Commands.add('selectMultiselectValue', selectMultiselectValue); Cypress.Commands.add('selectPlatformValue', selectPlatformValue); +Cypress.Commands.add('selectLobValue', selectLobValue); +Cypress.Commands.add('checkMultiSelectValue', checkMultiSelectValue); Cypress.Commands.add('checkPlatformValue', checkPlatformValue); +Cypress.Commands.add('checkLobValue', checkLobValue); + diff --git a/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/networkGenerator/network.control.generator.ts b/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/networkGenerator/network.control.generator.ts index e0418fcfa..fe6a2580d 100644 --- a/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/networkGenerator/network.control.generator.ts +++ b/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/networkGenerator/network.control.generator.ts @@ -64,7 +64,7 @@ export class NetworkControlGenerator { result.push(this._sharedControllersService.getLegacyRegion(networkInstance)); result.push(this._sharedControllersService.getTenantControl(serviceId, networkInstance)); result.push(this._sharedControllersService.getPlatformMultiselectControl(networkInstance, result, flags['FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT'])); - result.push(this._sharedControllersService.getLineOfBusinessControl(networkInstance)); + result.push(this._sharedControllersService.getMultiSelectLineOfBusinessControl(networkInstance, flags['FLAG_2006_NETWORK_LOB_MULTI_SELECT'])); } return result; @@ -89,7 +89,7 @@ export class NetworkControlGenerator { result.push(this._sharedControllersService.getLegacyRegion(networkInstance)); result.push(this._sharedControllersService.getTenantControl(serviceId, networkInstance)); result.push(this._sharedControllersService.getPlatformMultiselectControl(networkInstance, result, flags['FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT'])); - result.push(this._sharedControllersService.getLineOfBusinessControl(networkInstance)); + result.push(this._sharedControllersService.getMultiSelectLineOfBusinessControl(networkInstance, flags['FLAG_2006_NETWORK_LOB_MULTI_SELECT'])); result.push(this._sharedControllersService.getRollbackOnFailureControl(networkInstance)); } return result; diff --git a/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/sharedControlles/shared.controllers.service.ts b/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/sharedControlles/shared.controllers.service.ts index 97c5516db..32259b198 100644 --- a/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/sharedControlles/shared.controllers.service.ts +++ b/vid-webpack-master/src/app/shared/components/genericForm/formControlsServices/sharedControlles/shared.controllers.service.ts @@ -32,6 +32,10 @@ export class SharedControllersService { return this.getLineOfBusinessControlInternal(undefined, instance); }; + getMultiSelectLineOfBusinessControl = (instance: any, isMultiSelected: boolean): MultiselectFormControl => { + return this.getLobMultiselectControl(instance, isMultiSelected); + }; + getLineOfBusinessByOwningEntityControl = (instance?: any, serviceId?: string, controls?: FormControlModel[]): DropdownFormControl => { const service = this._store.getState().service.serviceInstance[serviceId]; const owningEntityName: string = service.owningEntityName; @@ -301,7 +305,7 @@ export class SharedControllersService { ); }; - getLobMultiselectControl = (instance: any, controls: FormControlModel[], isMultiSelected: boolean) : MultiselectFormControl => { + getLobMultiselectControl = (instance: any, isMultiSelected: boolean) : MultiselectFormControl => { return this.getMultiSelectFormControl( 'lineOfBusiness', 'Line of business', -- cgit 1.2.3-korg