source: trunk/grails-app/views/wizard/common/_wizard.gsp @ 101

Last change on this file since 101 was 101, checked in by duh, 10 years ago
  • refactored the wizard initial page to dynamically load pageOne, instead of rendering pageOne within the template itself. This was done because otherwise both the mainPage and pageOne had to contain duplicate logic. The ajaxified webflow works better this way.
  • added an <wizard:ajaxFlowRedirect...> tag which renders javascript code executing a jQuery ajax call (it actually wraps around <wizard:button...> tag but lifts the ajax call out of the button and wraps javascript tags around it)
  • improved the help / tooltip workings
  • extended the <wizard:button...> with an afterSuccess argument which executes some javascript after success. This is different from the default submitToRemote 'after' behaviour which is always executed in parallel with the ajax success call (hence, you javascript cannot access ajax result data while the afterSuccess method can)
  • Property svn:keywords set to Rev Author Date
File size: 722 bytes
Line 
1<%
2        /**
3         * Wizard template with first page rendered
4         *
5         * @author Jeroen Wesbeek
6         * @since 20100113
7         * @package wizard
8         * @see dbnp.studycapturing.WizardTagLib
9         * @see dbnp.studycapturing.WizardController
10         *
11         * Revision information:
12         * $Rev: 101 $
13         * $Author: duh $
14         * $Date: 2010-01-20 16:01:26 +0000 (wo, 20 jan 2010) $
15         */
16%>
17<div id="wizard" class="wizard">
18        <h1>Proof of concept AJAXified Grails Webflow Wizard</h1>
19        <g:form action="pages" name="wizardForm" id="wizardForm">
20                <div id="wizardPage">
21                        <wizard:ajaxFlowRedirect form="form#wizardForm" name="next" url="[controller:'wizard',action:'pages']" update="[success:'wizardPage',failure:'wizardError']" afterSuccess="handleHelpTooltips()" />
22                </div>
23                <g:render template="common/error"/>
24        </g:form>
25</div>
Note: See TracBrowser for help on using the repository browser.