Question


Virtusa
LK
Last activity: 27 Apr 2020 7:50 EDT
Showing Popup with a message after login in to the Case Manager Portal
Hi,
I need to add a popup message after the user is logged in. The user should click 'OK' and only then he can continue to work. Could you please Advice on how to get it done ?
***Edited by Moderator: Pallavi to update platform capability tags***
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!


Pegasystems Inc.
US
Try Extending ApplicationProfileSetup available activity to show some sort of Stream with custom alert code inside it.
This is an extension activity which gets called on launching portal after login.
Let me know how it goes.


Ernst & Young LLP
IN
Hi Harish,
Have tried show-Harness OR pxlaunchHarness activities in ApplicationProfileSetup but nothing seems to be working.
Can you suggest some way how to launch the Harness from APS activity and on the click of the Accept button launch the default portal
Updated: 14 Jun 2021 7:38 EDT


Pegasystems Inc.
IN
We can include the javascript in the Harness of the Case Manager portal and show the popup using the script.
Also please find the below article which might be helpful.
https://collaborate.pega.com/question/auto-launch-modal-popup-upon-screen-load


Ernst & Young LLP
IN
Hi Ashfaaque,
Are you able to implement this requirement? We are implementing the similar requirement in our project and tried multiple approaches:
1.) Creating a default dummy access group,portal,harness , section of the popup window and trying to switch the access group of the operator in ApplicationProfileSetup
2.) Trying to use show-Harness OR pxlaunchHarness activities in ApplicationProfileSetup but nothing seems to be working.
Can you let us know what approach are you trying


Virtusa
GB
1. Inside your harness, in any section add a button control and give any Test ID (like I have used "ScreenLoadModalButton"). Then add an event as Click and action as Launch Action. Mention the flow action which will be shown as modal popup on the screen. Make Visibility of the button as Never and Reserve space when hidden as checked. Else you can use visibility:hidden; to make it not visible on screen.
2. Create a js file with the following piece of code:
$(window).load(function () { document.querySelector('button[data-test-id="ScreenLoadModalButton"]').click(); });
3. Add the js script in Scripts and Styles tab of the harness where you have this section with modal popup.
4. Now launch the portal. On launch itself you should get a modal popup. You can also use Log Off action in the Cancel Button which will make the user logged off from the portal on click of Cancel.


Sun Life Financial Inc
IN
@ArpanP12 Thanks for this approach. I tried it but for me JS script is not getting executed. I have attached JS script screenshot and harness screenshot as well.
Could you please help here.
-
Vinod Kumar Vemula Rohit Sirivella


Virtusa
GB
Hi Sandeep,
For me it is working perfectly. Can you share the screenshot of your section where you have configured the modal and also the area in the harness where you have placed this section.
Also, are you testing the output from the Developer id? or any id other than Developer. With Developer id I meant id having SysAdm4 role in it. If you test from id having SysAdm4 role in it this should work. Operator ids not having SysAdm4 role will not give the desired output since they don't have pxTestID privilege in their ARO. To make this functionality work in ids other than developer add the pxTestID privilege to the ARO in their role. Then this should start working.
Regards,
Arpan


Sun Life Financial Inc
IN
Hi Arpan, Yes I am having required privilege and when i test a normal alert script , it is working fine but button click script is not working. Attaching screenshot.


Virtusa
GB
Hi Sandeep,
I have exactly the same configuration and no issue for me. I would suggest you to check few things:
1. Make the button visible always. Afterwards you can hide the layout in which it is present by giving the container format of the layout as Hidden. But, first check with visibility as Always.
2. After launching the portal, check the console if there is an error in executing the script. If there is no error and the script got executed successfully then check if the DOM element button is present with data-test-id attribute. Screenshot attached. Make sure this attribute value is same as that present in the script.
I am also sharing the screenshot of my configuration. Hope that helps.
Regards,
Arpan