In one of scenarios users plan any data in application developed by Integrated Planning via Web Application Designer (WAD) interface. This planned data should be approved by principals level.
User clicks button “Send for Approval” designed in WAD, but before sending for approval (by planning sequence execution) I want to be sure that button clicked not accidentally or I want to notice user with any notification before.
This blog demonstrates how to show alert message with YES/NO option before IP planning sequence run.
When a user clicks button “Send for Approval” alert message will appear with text “Do you really want …. ?”.
If YES clicked, planning sequence will be processed, otherwise no.
First add SCRIPT_ITEM in WAD to your template and in “Web Item Parameters” tab click on script (marked by red color in figure below).
In script editor choose “Create with Wizard” and select “Execute a Planning Sequence (Simple)” command.
Complete attaching of planning sequence and click OK.
var ok_var=confirm(“Are you sure you would like to …”)
Here will be all code generated by wizard except function definition
Be sure that at the end of function you added closing parentheses.
Goto button group/button properties and select in “Action” SCRIPT_FUNCTION.
Press OK and save web template.
Now, if user clicks this button, alert window will appear. Depending on user choice (YES/NO) planning sequence will be executed or no.