I need to create a multiple page form that upon submit the information
is saved to the database so the user can finish it later.

I want to be able to check the data filled out on the form and
depending on the values entered present different pages to the user.

I know this is possible, I just don't know how and the best way to
accomplish this. I have looked into the FormWizard but it looks like
it is more meant for forms that go in a straight line.

Formwizard
Page1 --> Page2 --> Page3 --> Page4 --> Page5 --> Page6 --> Page7 -->
Page8

I want my form to be able to skip a page or insert one, depending on
the input given on those pages.
Page1 --> Page3 --> Page5 --> Page7 --> Page8
or
Page1 --> Page2 --> Page4 --> Page5 --> Page8


Example of my model:

#models.py
from django.db import models

class Poll(models.Model):
    question1 = models.CharField(max_length=200)
    pub_date1 = models.DateTimeField('date published')
    question2_state = USStateField()
    question3 = models.CharField(max_length=200)
    question4 = models.CharField(max_length=200)
    question5 = models.CharField(max_length=200)
    question6...
    agree = models.BooleanField(help_text='I agree that this is
correct')

#forms.py
from django import forms

 class PollForm1(forms.Form):
     question1 = forms.CharField(max_length=200)
     question2 = forms.ChoiceField(max_length=200)

 class PollForm2(forms.Form):
     question3 = forms.CharField(max_length=200)

 class PollForm3(forms.Form):
     question4 = forms.CharField(max_length=200)

 class PollForm4(forms.Form):
     question5 = forms.CharField(max_length=200)
     question6 = forms.CharField(max_length=200)

 class PollForm5...
 class PollFormN...
     agree = forms.BooleanField()

Thanks in advance for the help!
--~--~---------~--~----~------------~-------~--~----~
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+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to