Opened 18 years ago
Closed 17 years ago
#4542 closed (fixed)
generic localflavor date field
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | contrib.localflavor | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
I've added a patch to add an AUDateField
and AUDateTimeField
to the Australian localflavor contrib. They're just extensions of regular DateField
and DateTimeField
's that use Australian "dd/mm/yy" (etc) date formats by default.
Another possibility would be to just define AU_DATE_INPUT_FORMATS
and AU_DATETIME_INPUT_FORMATS
tuples and then pass them in to regular DateField
's as the input_format argument.
Attachments (3)
Change History (10)
by , 18 years ago
Attachment: | au_dates.diff added |
---|
comment:1 by , 18 years ago
Component: | Uncategorized → django.contrib.localflavor |
---|---|
Has patch: | set |
Owner: | changed from | to
comment:2 by , 18 years ago
Triage Stage: | Unreviewed → Design decision needed |
---|
I'll move to design decision until the way to handle this is agreed on. Perhaps you could take it to the developer's group?
comment:3 by , 18 years ago
Triage Stage: | Design decision needed → Accepted |
---|
We should probably give these better names, since they aren't specific to Australia. The North American format is by far the minority case.
The settings aren't a good idea, because it will conflict with far too many places where there are existing date format strings and we'll be fielding actual and perceived bug reports until the cows come home. Plus, again, they aren't .au specific.
We might make a "generic" directory (or similar name) under localflavor/ for this sort of thing. Then the classes can just be called DateField and DateTimeField (because the import location namespaces them sufficiently).
Patch is missing tests, too.
comment:4 by , 18 years ago
Needs tests: | set |
---|---|
Patch needs improvement: | set |
comment:5 by , 18 years ago
Last patch is against 0.96 (before localflavor tests were added) because I can't access svn.
comment:6 by , 17 years ago
Needs tests: | unset |
---|---|
Patch needs improvement: | unset |
Summary: | AU localflavor date field → generic localflavor date field |
Triage Stage: | Accepted → Ready for checkin |
4542 looks good, and appears to answer all MT's quibbles above.
comment:7 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Australian date fields