1
0
mirror of https://github.com/django/django.git synced 2025-11-07 07:15:35 +00:00

Fixed #8068 - Added Kuwaiti (kw) localflavor. Thanks to Ahmad Al-Ibrahim for providing the patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12042 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Jannis Leidel
2010-01-01 21:32:24 +00:00
parent 3825bb2350
commit 82b33b1d80
6 changed files with 93 additions and 0 deletions

View File

@@ -52,6 +52,7 @@ Countries currently supported by :mod:`~django.contrib.localflavor` are:
* India_
* Italy_
* Japan_
* Kuwait_
* Mexico_
* `The Netherlands`_
* Norway_
@@ -95,6 +96,7 @@ Here's an example of how to use them::
.. _India: `India (in\_)`_
.. _Italy: `Italy (it)`_
.. _Japan: `Japan (jp)`_
.. _Kuwait: `Kuwait (kw)`_
.. _Mexico: `Mexico (mx)`_
.. _Norway: `Norway (no)`_
.. _Peru: `Peru (pe)`_
@@ -410,6 +412,18 @@ Japan (``jp``)
A ``Select`` widget that uses a list of Japanese prefectures as its choices.
Kuwait (``kw``)
===============
.. class:: kw.forms.KWCivilIDNumberField
A form field that validates input as a Kuwaiti Civil ID number. A valid
Civil ID number must obey the following rules:
* The number consist of 12 digits.
* The birthdate of the person is a valid date.
* The calculated checksum equals to the last digit of the Civil ID.
Mexico (``mx``)
===============