From b4ebca28d82eeb927c30720b97ba14838482c497 Mon Sep 17 00:00:00 2001 From: Nizamudeen A Date: Sun, 24 Oct 2021 00:36:51 +0530 Subject: [PATCH] mgr/dashboard: Fix for form inside form closing issue After the angular 11 upgrade the form in form behaviour got broken when one tries to close that "embedded" form. This commit is to fix that behaviour. Fixes: https://tracker.ceph.com/issues/53020 Signed-off-by: Nizamudeen A --- .../orchestrator/workflow/nfs/nfs-export.po.ts | 5 +++++ .../iscsi-target-form.component.html | 4 ++-- .../nfs-form-client.component.html | 5 +++-- .../nfs-form-client/nfs-form-client.component.ts | 15 ++++++++------- 4 files changed, 18 insertions(+), 11 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/cypress/integration/orchestrator/workflow/nfs/nfs-export.po.ts b/src/pybind/mgr/dashboard/frontend/cypress/integration/orchestrator/workflow/nfs/nfs-export.po.ts index 91dfdf48d1015..03b3bb18dac84 100644 --- a/src/pybind/mgr/dashboard/frontend/cypress/integration/orchestrator/workflow/nfs/nfs-export.po.ts +++ b/src/pybind/mgr/dashboard/frontend/cypress/integration/orchestrator/workflow/nfs/nfs-export.po.ts @@ -28,6 +28,11 @@ export class NFSPageHelper extends PageHelper { cy.get('button[name=add_client]').click({ force: true }); cy.get('input[name=addresses]').type(client['addresses']); + // Check if we can remove clients and add it again + cy.get('span[name=remove_client]').click({ force: true }); + cy.get('button[name=add_client]').click({ force: true }); + cy.get('input[name=addresses]').type(client['addresses']); + cy.get('cd-submit-button').click(); } diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-form/iscsi-target-form.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-form/iscsi-target-form.component.html index eb4b9e3a6d048..852866a86db2c 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-form/iscsi-target-form.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-form/iscsi-target-form.component.html @@ -337,7 +337,7 @@ formArrayName="initiators">
+ [formGroup]="initiator">
Initiator: {{ initiator.getValue('client_iqn') }}