Opened 13 years ago

Closed 13 years ago

#17152 closed Bug (fixed)

WizardView template documentation incorrect

Reported by: Bradley Ayers <bradley.ayers@…> Owned by: nobody
Component: contrib.formtools Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

https://docs.djangoproject.com/en/dev/ref/contrib/formtools/form-wizard/#creating-templates-for-the-forms has sample HTML showing how a wizard could be rendered.

However the this code is missing type="submit" on the buttons.

<button name="wizard_prev_step" value="{{ wizard.steps.first }}">{% trans "first step" %}</button>
<button name="wizard_prev_step" value="{{ wizard.steps.prev }}">{% trans "prev step" %}</button>

Attachments (1)

17152.diff (2.8 KB ) - added by Bradley Ayers <bradley.ayers@…> 13 years ago.

Download all attachments as: .zip

Change History (9)

comment:1 by Julien Phalip, 13 years ago

Triage Stage: UnreviewedReady for checkin

comment:3 by Julien Phalip, 13 years ago

Triage Stage: Ready for checkinAccepted

Back to 'Accepted' as it needs more than just a trivial doc patch.

comment:4 by Bradley Ayers <bradley.ayers@…>, 13 years ago

I think this is also a bad example on how to "go back". If you have a form that has a file field, and you choose a file to upload, and then click "back", it's going to submit the form, meaning your file will be uploaded. Although there's no other way to do it using WizardView, I think this limitation should be made more obvious (and urge developers to use NamedUrlWizardView instead which allows you to just use a hyperlink to the previous form.)

by Bradley Ayers <bradley.ayers@…>, 13 years ago

Attachment: 17152.diff added

comment:5 by Bradley Ayers <bradley.ayers@…>, 13 years ago

Has patch: set

comment:6 by Bradley Ayers <bradley.ayers@…>, 13 years ago

I've incorporated #17153 into this patch.

comment:7 by Julien Phalip, 13 years ago

Triage Stage: AcceptedReady for checkin

comment:8 by Julien Phalip, 13 years ago

Resolution: fixed
Status: newclosed

In [17072]:

Fixed #17152 -- Fixed a few anomalies in the contrib.formtools documentation and templates. Thanks, Bradley Ayers.

Note: See TracTickets for help on using tickets.
Back to Top