equal
deleted
inserted
replaced
2 NL-specific Form helpers |
2 NL-specific Form helpers |
3 """ |
3 """ |
4 |
4 |
5 import re |
5 import re |
6 |
6 |
7 from django.newforms import ValidationError |
7 from django.forms import ValidationError |
8 from django.newforms.fields import Field, Select, EMPTY_VALUES |
8 from django.forms.fields import Field, Select, EMPTY_VALUES |
9 from django.utils.translation import ugettext as _ |
9 from django.utils.translation import ugettext_lazy as _ |
10 from django.utils.encoding import smart_unicode |
10 from django.utils.encoding import smart_unicode |
11 |
11 |
12 pc_re = re.compile('^\d{4}[A-Z]{2}$') |
12 pc_re = re.compile('^\d{4}[A-Z]{2}$') |
13 sofi_re = re.compile('^\d{9}$') |
13 sofi_re = re.compile('^\d{9}$') |
14 numeric_re = re.compile('^\d+$') |
14 numeric_re = re.compile('^\d+$') |