Fixed #5939 -- Added normalization for New Brunswick in the Canadian provinces.
Thanks, rajesh.dhawan@gmail.com. git-svn-id: http://code.djangoproject.com/svn/django/trunk@6744 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
e2b03bd0c2
commit
4cbc8c62cf
1
AUTHORS
1
AUTHORS
|
@ -101,6 +101,7 @@ answer newbie questions, and generally made Django that much better:
|
|||
Alex Dedul
|
||||
deric@monowerks.com
|
||||
Max Derkachev <mderk@yandex.ru>
|
||||
Rajesh Dhawan <rajesh.dhawan@gmail.com>
|
||||
Sander Dijkhuis <sander.dijkhuis@gmail.com>
|
||||
Jordan Dimov <s3x3y1@gmail.com>
|
||||
dne@mayonnaise.net
|
||||
|
|
|
@ -33,6 +33,8 @@ PROVINCES_NORMALIZED = {
|
|||
'british columbia': 'BC',
|
||||
'mb': 'MB',
|
||||
'manitoba': 'MB',
|
||||
'nb': 'NB',
|
||||
'new brunswick': 'NB',
|
||||
'nf': 'NF',
|
||||
'newfoundland': 'NF',
|
||||
'newfoundland and labrador': 'NF',
|
||||
|
|
|
@ -147,6 +147,10 @@ u'BC'
|
|||
u'NS'
|
||||
>>> f.clean(' manitoba ')
|
||||
u'MB'
|
||||
>>> f.clean(' new brunswick ')
|
||||
u'NB'
|
||||
>>> f.clean('NB')
|
||||
u'NB'
|
||||
>>> f.clean('T2S 2H7')
|
||||
Traceback (most recent call last):
|
||||
...
|
||||
|
|
Loading…
Reference in New Issue