Tuesday, November 13, 2012

Re: Form wizard step back

>Separate step is separate browser interaction. Even if you did this with
>AJAX, other requests can come in in between actions. Other users don't get
>blocked from accessing the site just because one is in the middle of
>registering. Sorry, but that's the way the web works.
>
>By the way, you don't need anything else to create the account. You can
>fill in any required fields with place holder values, and leave login
>disabled until you get your real minimum.


This is really not a solution. No need of blocking of anything, i just need to redirect user into first step in case login gets taken in the middle of his registration. That's all :) I won't change the whole API (yes, registration is done on external server via SOAP API) because of frontend limitations.



Any other suggestions? I wonder why this can't be done. I was examinating how 'Go back' button works and this is the source:

wizard_goto_step = self.request.POST.get('wizard_goto_step', None)
if wizard_goto_step and wizard_goto_step in self.get_form_list():
self.storage.current_step = wizard_goto_step
form = self.get_form(
data=self.storage.get_step_data(self.steps.current),
files=self.storage.get_step_files(self.steps.current))
return self.render(form)


If i'm trying to simulate it in done() methond of my Form wizard object i'm always getting the first step (no matter which step i specify), all data is lost and it is even rendered completely broken (no form elements).


azur

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate