Support Article
Not able to launch modal window on condition based
SA-88370
Summary
A Date control is configured in a section with Refresh-Section and Launch-LocalAction (modal dialog). The Local action has a When rule configured. The first time the value of Property1 is set to a date greater than Property2, the modal dialog is not launched. However, the second time the value is changed, the modal dialog is launched.
Error Messages
Not Applicable
Steps to Reproduce
- Navigate to Cell Properties > Actions.
- Configure a section with a DateTime control.
- Add a Change event.
- Add a Local Action.
- In Conditions, set the When condition to Associated Property > .Prop2.
At runtime, the When condition evaluates correctly the second time and launches the modal dialog. When the date is changed the first time, the modal dialog is not launched.
Root Cause
The values from the Date fields are compared as strings in the propertyRefCondition function in the pzpega_ui_event_conditions JavaScript. This resulted in incorrect comparison. This change is in response to the conditions in the Action configuration which do not work.
For this to work, the properties referred in the condition must be either change tracked or be present in the Document Object Model (DOM).
Resolution
Perform the following local-change:
- Configure the comparison property (for example, Property2) in the same section. To hide the Property2 control, add relevant styles in the UserWorkForm.
- Apply HFix-55949.
Published December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.