diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2018-01-21 21:05:28 +0100 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2018-01-21 21:05:28 +0100 |
commit | 781d7824ca939d3794d3ab098ea8a2311fc2c643 (patch) | |
tree | 695caca9fafeec457b44d9fcc169315de08f8b7b /archaeological_files/forms.py | |
parent | f4bad8942ed753b85fcf7bdb00ce666bebe53c97 (diff) | |
download | Ishtar-781d7824ca939d3794d3ab098ea8a2311fc2c643.tar.bz2 Ishtar-781d7824ca939d3794d3ab098ea8a2311fc2c643.zip |
Arcaheological file: adapt forms, models and sheet
Diffstat (limited to 'archaeological_files/forms.py')
-rw-r--r-- | archaeological_files/forms.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/archaeological_files/forms.py b/archaeological_files/forms.py index b075c6fc8..b87ef9ba5 100644 --- a/archaeological_files/forms.py +++ b/archaeological_files/forms.py @@ -47,6 +47,7 @@ from bootstrap_datepicker.widgets import DatePicker class FileSelect(TableSelect): + search_vector = forms.CharField(label=_(u"Full text search")) year = forms.IntegerField(label=_("Year")) numeric_reference = forms.IntegerField(label=_("Numeric reference")) internal_reference = forms.CharField(max_length=200, @@ -125,6 +126,7 @@ class FileSelect(TableSelect): class FileFormSelection(forms.Form): + SEARCH_AND_SELECT = True form_label = _("Archaeological file search") associated_models = {'pk': models.File} currents = {'pk': models.File} @@ -142,6 +144,7 @@ class FileFormSelection(forms.Form): raise forms.ValidationError(_(u"You should select a file.")) return cleaned_data + DATE_SOURCE = (('creation', _(u"Creation date")), ("reception", _(u"Reception date"))) |