Opened 7 years ago

Closed 5 years ago

Last modified 5 years ago

#11251 closed New feature (fixed)

Australian Local Flavo(u)r models would be nice

Reported by: Simon Meers <DrMeers@…> Owned by: Simon Meers
Component: contrib.localflavor Version: master
Severity: Normal Keywords: Australia
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

US localflavor provides models as well as forms; it appears to be the only one. I have created a patch which provides Australian models (and documentation).

Attachments (4)

au-models.diff (2.6 KB) - added by Simon Meers <DrMeers@…> 7 years ago.
Patch which provides django.contrib.localflavor.au.models and associated documentation.
au-models.2.diff (8.5 KB) - added by Simon Meers 7 years ago.
models, forms, tests and documentation
11251.au-models.py (8.2 KB) - added by Julien Phalip 5 years ago.
Updated patch for new localflavor tests structure
11251.au-models.diff (8.2 KB) - added by Julien Phalip 5 years ago.
Oops, this time in diff format

Download all attachments as: .zip

Change History (19)

Changed 7 years ago by Simon Meers <DrMeers@…>

Attachment: au-models.diff added

Patch which provides django.contrib.localflavor.au.models and associated documentation.

comment:1 Changed 7 years ago by Simon Meers

Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset
Resolution: fixed
Status: newclosed

comment:2 Changed 7 years ago by Simon Meers

Resolution: fixed
Status: closedreopened

comment:3 Changed 7 years ago by Alex Gaynor

Triage Stage: UnreviewedAccepted

comment:4 Changed 7 years ago by Jannis Leidel

milestone: 1.2
Needs tests: set
Version: 1.0SVN

This will need some tests to get checked in. You can follow the example of the US model fields which are tested in source:django/trunk/tests/regressiontests/localflavor

comment:5 Changed 7 years ago by Alex Gaynor

This needs to be updated post multi-db. Best solution is to do something like: http://code.djangoproject.com/changeset/11857 and remove the explicit DB column type.

comment:6 Changed 7 years ago by Alex Gaynor

Patch needs improvement: set

comment:7 Changed 7 years ago by Russell Keith-Magee

milestone: 1.2
Version: SVN

comment:8 Changed 7 years ago by Simon Meers

Needs tests: unset
Owner: changed from nobody to Simon Meers
Patch needs improvement: unset
Status: reopenednew
Version: SVN

OK, I've updated the models for multi-db, added regression tests and made a few other improvements.

I suggest the USLocalflavorTests adopt a similar regex approach rather than explicitly testing output which is more subject to irrelevant changes. I wasn't sure whether to take the liberty of doing so myself, especially in an unrelated ticket.

Changed 7 years ago by Simon Meers

Attachment: au-models.2.diff added

models, forms, tests and documentation

comment:9 Changed 6 years ago by Simon Meers

Would we be better off closing this and leaving such things out of Django core/contrib? DDN I guess...

comment:10 Changed 6 years ago by Jannis Leidel

milestone: 1.3

No, that's fine, the patch looks good.

comment:11 Changed 6 years ago by Julien Phalip

Severity: Normal
Type: New feature

Changed 5 years ago by Julien Phalip

Attachment: 11251.au-models.py added

Updated patch for new localflavor tests structure

Changed 5 years ago by Julien Phalip

Attachment: 11251.au-models.diff added

Oops, this time in diff format

comment:12 Changed 5 years ago by Julien Phalip

Triage Stage: AcceptedReady for checkin

The patch looks great. I've just updated it so it uses the new localflavor tests structure introduced in [13505].

comment:13 Changed 5 years ago by Simon Meers

Cool, thanks Julien.

Wow, that was a dusty old patch... though I guess there are a lot of dustier ones on older tickets!

comment:14 Changed 5 years ago by Jannis Leidel

Resolution: fixed
Status: newclosed

In [16066]:

Fixed #11251 -- Extended Australian localflavor to ship a few model fields additionally. Thanks, Simon Meers and Julien Phalip.

comment:15 Changed 5 years ago by Jacob

milestone: 1.3

Milestone 1.3 deleted

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