Opened 13 years ago
Last modified 13 years ago
#17283 closed Bug
Adding Human Readable Name to forms.DateField with input_formats option causes input_format to complain about multiple values for input_formats — at Version 1
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | Forms | Version: | 1.3-rc |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description (last modified by )
The following code snippet
from django import forms from django.utils.translation import ugettext_lazy as _ class SearchForm( forms.Form): d_o_b = forms.DateField( _( 'Human Readable Name'), required=False, input_formats=('%d-%m-%Y',))
causes django to complain __init__() got multiple values for keyword argument 'input_formats'
while
d_o_b = form.DateField( required=False, input_formats=('%d-%m-%Y',))
works fine.
Note:
See TracTickets
for help on using tickets.
Fixed formatting. Please use WikiFormatting and preview before posting.