Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X
I have a wizard with 4 tables in it and defined custom button list for it i.e. "Validate" and Publish.
Once user click on the validate button. I wan to refresh the whole Wizard page. I tried using beforeJS and afterJS with some javascript function.
Objective : To refresh wizard page on Action perform on wizard button.
Wizard Definition:
<jca:wizard title="Publish Bill of Material" buttonList="XXXReplacementWizardButtons">
<jca:wizardStep action="show_mvc_content_bom" type="XXXwizard" label="Publish BOM"/>
</jca:wizard>
Wizard page mutliconfig table of four tables
Action-Model Decleration:
<model name="XXXReplacementWizardButtons" >
<action name="validate" type="bompush"/>
<action name="publish" type="bompush"/>
</model>
Action Decleration:
<objecttype name="bompush" class="" resourceBundle="com.XXX.agile.ui.resource.NavigationRB">
<action name="validate">
<command class="com.XXX.agile.action.table.bom.AgileValidateBOMAction" method="execute" afterJS="refreshBOMWizard()"/>
</action>
<action name="publish">
<command class="com.XXX.agile.action.table.bom.AgilePublishBOMAction" onClick="verifyAgileResponse()"/>
</action>
</objecttype>
Javascript Function:custom.jsfrog
/**
* Refresh Wizard
*/
function refreshBOMWizard()
{
alert("refreshing table");
reloadAccessTable("table1");
reloadAccessTable("table2);
reloadAccessTable("table3");
reloadAccessTable("table4");
}
/**
* Table relaod
*/
function reloadAccessTable (tableId){var table = tableUtils.getTable(tableId);if(table){PTC.jca.table.Utils.reload(tableId);}return true;}