2010-01-02 05:33:00 +08:00
|
|
|
"""
|
|
|
|
UK-specific Form helpers
|
|
|
|
"""
|
|
|
|
|
2011-10-18 08:47:49 +08:00
|
|
|
from __future__ import absolute_import
|
|
|
|
|
|
|
|
from django.contrib.localflavor.ie.ie_counties import IE_COUNTY_CHOICES
|
2010-01-02 05:33:00 +08:00
|
|
|
from django.forms.fields import Select
|
|
|
|
|
2011-10-18 08:47:49 +08:00
|
|
|
|
2010-01-02 05:33:00 +08:00
|
|
|
class IECountySelect(Select):
|
|
|
|
"""
|
|
|
|
A Select widget that uses a list of Irish Counties as its choices.
|
|
|
|
"""
|
|
|
|
def __init__(self, attrs=None):
|
|
|
|
super(IECountySelect, self).__init__(attrs, choices=IE_COUNTY_CHOICES)
|