[Dojo-interest] Validation, Forms, Dialogs and WizardPanes
Gavin Henry
ghenry at perl.me.uk
Tue Jan 16 14:23:45 MST 2007
Hi All,
I've been in irc a few days now, but thought it best to take the time out
and describe what I am trying to achieve to the list.
I have a dojo Form widget, which has a dojo Wizard inside. Each form text
field is a dojo Validate widget.
I've setup a blocking dialog, that says "Please fill out the missing
fields". That bit is easy.
What I want to do, using the passFunction in each wizard step, is to
search for missing/invalid inputs (in that pane only), which in turn are
dojo validate widgets, push the missing ones onto an array, then if the
array has something in it, pop up the dialog.
My problems are:
1. Make a dialog return false, so the wizard can't move on. I've only seen
a return "blah missing" do that.
2. Search the wizardpane step for missing/invalid items. Each wizard pane
has an id, so that could be used.
3. Tie the first 2 steps into a general passFunction for each pane/step.
Once these are solved, the last 2 things I want to do is to have one
wizard pane effect the next one. For example, if the "Use for billing
info" is checked in one step, move that data into the next step. Should be
ok to do (getValues()/SetValues() as joose suggested).
Grab the whole dojo form and present the results for final review. I think
that is fine, again with getValues/setValues etc.
I've also done it so the cancel/done buttons disappear once they've
clicked "done", via the doneFunction of the wizard.
This is for a soon to be live site, so I'll happily post that link for
others to learn from my battles ;-)
Thanks for your time,
Gavin.
--
Walking the road to enlightenment... I found a penguin and a camel on the
way..... Fancy a yourname at perl.me.uk? Just ask!!!
http://perlmonks.org/?node_id=386673
More information about the Dojo-interest
mailing list