Pakistan (pk
)¶
Forms¶
Pakistani-specific Form helpers
-
class
localflavor.pk.forms.
PKPhoneNumberField
(max_length=None, min_length=None, *args, **kwargs)[source]¶ A form field that validates input as an Pakistani phone number.
Valid numbers have nine to eleven digits.
Models¶
-
class
localflavor.pk.models.
PKPhoneNumberField
(*args, **kwargs)[source]¶ A model field that checks that the value is a valid Pakistani phone number (nine to eleven digits).
-
description
= u'Pakistani Phone number'¶
-
-
class
localflavor.pk.models.
PKPostCodeField
(*args, **kwargs)[source]¶ A model field that forms represent as a
PKPostCodeField
field and stores the five-digit Pakistani postcode in the database.-
description
= u'Pakistani Postcode'¶
-
Data¶
-
localflavor.pk.pk_states.
STATE_CHOICES
= (('PK-JK', u'Azad Jammu & Kashmir'), ('PK-BA', u'Balochistan'), ('PK-TA', u'Federally Administered Tribal Areas'), ('PK-GB', u'Gilgit-Baltistan'), ('PK-IS', u'Islamabad'), ('PK-KP', u'Khyber Pakhtunkhwa'), ('PK-PB', u'Punjab'), ('PK-SD', u'Sindh'))¶ An alphabetical list of states for use as choices in a formfield.