After confirmation, navigate to first tab of wizard...
Pretty much, everything is said in title of topic.What I need to achieve is that when I am in last (confirm) tab of wizard and click on my button, after everything is done, I want to back to first tab of wizard. Of course, everything in wizard should be reset after that.
PrimeFaces 3.0.M3
Mojarra 2.0.2 (FCS b10)
Glassfish 3.0.1
JSF 2.1.1 RI
Netbeans IDE 6.9.1
Mojarra 2.0.2 (FCS b10)
Glassfish 3.0.1
JSF 2.1.1 RI
Netbeans IDE 6.9.1
You can use "flowListener" attribute with a server side method to invoke when wizard is going forward and back.
JSF:
JAVA:
JSF:
Code: Select all
<p:wizard id="wiz" widgetVar="wiz1" flowListener="#{backingBean.handleFlow}">
<p:tab id="s10" title="step1">
Code: Select all
public String handleFlow(final FlowEvent event)
{
final String currentStepId = event.getOldStep();
String stepToGo = event.getNewStep();
if (currentStepId.equalsIgnoreCase("...")) //last step
{
... //reset fields
stepToGo = "s10";
}
return stepToGo;
}
Rüdiger
PrimeFaces 11.0 | Ultima 2.0
Mojarra 2.3 | Tomcat 8/9 | Win7/10 | OS X 10.14
PrimeFaces 11.0 | Ultima 2.0
Mojarra 2.3 | Tomcat 8/9 | Win7/10 | OS X 10.14
-
- Information
-
Who is online
Users browsing this forum: No registered users and 27 guests