question on how-do doc Create a wizard or multi-page form with Form Builder

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

question on how-do doc Create a wizard or multi-page form with Form Builder

Noriko Curtis
 Hello, I tried the wizard-form.xml from the how to document at
http://wiki.orbeon.com/forms/how-to/form-builder-wizard
The technique works great, but the submitted form does not get listed
in the form runner's summary page. I noticed when I removed the code
starting <fr:buttons>, which makes the form a single page, the
submitted forms get listed in the summary page. But enabling the next
button is the whole purpose of the how-to doc. I wonder the fr:buttons
code overrides the fr's default detail pages' buttons. If someone
could guide me a way to save a list of forms while using the how-to
doc's technique, I would greatly appreciate it. Noriko


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: question on how-do doc Create a wizard or multi-page form with Form Builder

Alessandro  Vernet
Administrator
Noriko,

That's right: explicitly providing your own buttons inside an
<fr:buttons> overrides the buttons you configured with
oxf.fr.detail.buttons. You can see where this is done in the Form
Runner source:

https://github.com/orbeon/orbeon-forms/blob/master/src/resources/apps/fr/components/view.xsl#L526

If you want to include other buttons, you need to include them
explicitly inside the <fr:buttons>, e.g.:

<fr:buttons>
    <fr:save-button/>
    <fr:button xxforms:modal="true"
ref=".[instance('fr-form-instance')/internal/part != 'confirmation']">
        ...
    </fr:button>
</fr:buttons>

I also added a note about this on the wiki (see the section "Including
standard buttons"):

http://wiki.orbeon.com/forms/how-to/form-builder-wizard

Alex

On Fri, Jan 14, 2011 at 9:58 PM, Noriko Curtis <[hidden email]> wrote:

>  Hello, I tried the wizard-form.xml from the how to document at
> http://wiki.orbeon.com/forms/how-to/form-builder-wizard
> The technique works great, but the submitted form does not get listed
> in the form runner's summary page. I noticed when I removed the code
> starting <fr:buttons>, which makes the form a single page, the
> submitted forms get listed in the summary page. But enabling the next
> button is the whole purpose of the how-to doc. I wonder the fr:buttons
> code overrides the fr's default detail pages' buttons. If someone
> could guide me a way to save a list of forms while using the how-to
> doc's technique, I would greatly appreciate it. Noriko
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> OW2 mailing lists service home page: http://www.ow2.org/wws
>
>


--
Orbeon Forms - Web forms, open-source, for the Enterprise -
http://www.orbeon.com/
My Twitter: http://twitter.com/avernet


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|

Re: Re: question on how-do doc Create a wizard or multi-page form with Form Builder

Noriko Curtis
Alex, Thank you for the reply. In the mean time, I added  my own
"Next" button on each fr:section, just like your example,.
xforms-wizard-switch, but I would rather use FRunner's standard
buttons all together. Now, I would like Save button to appear only at
the confirmation page,  tried
 <fr:save-button  ref=".[instance('fr-form-instance')/internal/part =
'confirmation']"/>
 but still Save button appears on every page. Any suggestions on this?
 Noriko Curtis


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Re: question on how-do doc Create a wizard or multi-page form with Form Builder

Alessandro  Vernet
Administrator
Noriko,

You could put a ref directly on the <fr:save-button/> if it was implemented in XBL. At some point it will, but right now this <fr:save-button/> is just processed by some XSLT in buttons.xsl. So for now, you need to add a group around the <fr:save-button/>, as follows:

<fr:buttons>
    <xforms:group ref=".[instance('fr-form-instance')/section/page = '1']">
        <fr:save-button/>
    </xforms:group>
</fr:buttons>

Alex
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet