Question
Pegasystems Inc.
IN
Last activity: 21 Jul 2017 5:53 EDT
Multiple modal dialog windows needs to be closed on a single click
I have section in which i have a link, clicking on which will open a modal dialog window. This modal window will have few text input fields and if user clicks on cancel button in the modal window then another dialog should appear asking for confirmation with ok and cancel button. Clicking on Ok button should close both the confirmation and the original dialog and the initial section should be displayed. Clicking on cancel button in the confirmation dialog should close only the confirmation dialog.
I am not sure how to configure to close multiple modal windows in a single click. Does anyone have any idea how to address this requirement?
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Pegasystems Inc.
US
user clicks on cancel button in the modal window then another dialog should appear asking for confirmation with ok and cancel button.
Could you elaborate on how you did this ? Is this a JS confirm message you are using ?
Based on the response to the confirm message, may be you call the modal dialog cancel from there. I'll try to whip up a local sample and update here if I get the results.
Pegasystems Inc.
IN
I did not use any JS scripts. In the first modal dialog if the user clicks on cancel button i have configured in the actions tab of the cancel button to show another modal dialog that has the close confirmation message with ok and cancel buttons. Now i am stuck-up at how to configure the ok button on the second modal dialog , it should be closing both the modal dialogs when user clicks on ok button.
Pegasystems Inc.
US
Pega does not allow a modal dialog to be launched from a modal dialog. So curious, how you did this. May be you are launching an overlay ?
Can you show the screen shots of the "Cancel" on the first modal ?
Basically you want the cancel on the second to cancel both the dialogs ? IS that right ?
-
Lakshman Kumar Thota
Pegasystems Inc.
IN
Yeah i am launching an overlay on click of cancel in first modal dialog and you got it right , i want to close both the dialogs when the user clicks on cancel on the 2nd window. I know we can use JS to show the confirmation popup but my client does not want me to have any JS as it will give a guardrail warning. So i want to achieve this functionality without any JS script or custom code.
Instellars Global Consulting Pvt Ltd
IN
Hi vamsikrishnaM,
On-Click of the Ok button. Simply add "refresh this current harness" which will close both the modal windows. If there is some operations to be performed before the close means do call "run activity" or "data transform" or "anyother action" before "refresh this current harness".
Hope this will resolve your issue.
Thanks,
Suresh Kumar J
Pegasystems Inc.
US
I tested Suresh's suggestion and it does help achieve the requirement. Thanks Suresh!
Refresh may cause you to lose some changes on the page that had made before launching the modal, so test / take necessary precautions before using this approach.
Instellars Global Consulting Pvt Ltd
IN
Hi Krithiga,
Refresh this Current Harness by default it will post the values to clipboard unless we select "Disable submit on refresh" Checkbox. So the Data is not lost unless we select this option.
Thanks,
Suresh Kumar J
Pegasystems Inc.
US
Hi,
Please check OOTB modal dialog behavior in User Interface->UI Gallery: Modal Dialog.
A Modal Dialog contains two buttons at the bottom: Cancel and Submit.
When user clicks on Cancel, the Modal Dialog will disappear. Please let us know how your Cancel button in Modal Dialog will launch another confirmation dialog. Do you have any special configuration applied on that Cancel button? Please share.
Thanks,
Susan
Accenture
US
Hi All,
Has anyone face this issue earlier?
I have a requirement where I want to call a modal window dialog from a modal window.
steps :
1) Click on the button in harness.
2) It opens up a 1st modal window (local action). On submit of 1st modal window, expectation is to open a 2nd modal window(local action) and close the 1st modal window.
Note : Primary class of harness is different from the class of local actions.
This comment has been branched out as a new node and the new thread can be followed here
Pegasystems Inc.
IN
Hi,
You have replied to an older thread which lacks activity. To gather better visibility for your question, I have branched it to create a new question. You may continue your conversation on this thread: https://collaborate.pega.com/question/call-modal-window-dialog-modal-window
Hope the information is helpful.
Thanks!