diff options
author | Étienne Loks <etienne.loks@peacefrogs.net> | 2011-03-28 18:12:26 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@peacefrogs.net> | 2011-03-28 18:12:26 +0200 |
commit | c5245cfcfd596ceaf250aeed81b33e994638ddd7 (patch) | |
tree | 0f8549112e57bc2089d9280dce695fa826a8cf7f /ishtar/furnitures/forms.py | |
parent | 5650ec7925b6ace9c3db7ac37378da7e03805ab3 (diff) | |
download | Ishtar-c5245cfcfd596ceaf250aeed81b33e994638ddd7.tar.bz2 Ishtar-c5245cfcfd596ceaf250aeed81b33e994638ddd7.zip |
Adjust context record selection (closes #311)
Diffstat (limited to 'ishtar/furnitures/forms.py')
-rw-r--r-- | ishtar/furnitures/forms.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/ishtar/furnitures/forms.py b/ishtar/furnitures/forms.py index 3487dbb94..c6d10787e 100644 --- a/ishtar/furnitures/forms.py +++ b/ishtar/furnitures/forms.py @@ -1793,9 +1793,11 @@ class RecordSelect(forms.Form): widget=widgets.JQueryAutoComplete("/" + settings.URL_PATH + \ 'autocomplete-town', associated_model=models.Town), validators=[models.valid_id(models.Town)]) - parcel__operation__operation_type = forms.ChoiceField( - label=_("Operation type"), choices=models.OperationType.get_types()) - parcel__year = forms.IntegerField(label=_("Year")) + parcel__operation__year = forms.IntegerField(label=_("Year")) + datings__period = forms.ChoiceField(label=_("Period"), + choices=models.Period.get_types()) + unit = forms.ChoiceField(label=_("Unit type"), + choices=models.Unit.get_types()) class RecordFormSelection(forms.Form): form_label = _("Context record") @@ -1816,13 +1818,13 @@ class RecordFormSelection(forms.Form): class RecordFormGeneral(forms.Form): form_label = _("General") - associated_models = {'parcel':models.Parcel,} + associated_models = {'parcel':models.Parcel, 'unit':models.Unit} parcel = forms.ChoiceField(label=_("Parcel"), choices=[]) label = forms.CharField(label=_(u"Label"), validators=[validators.MaxLengthValidator(200)]) description = forms.CharField(label=_(u"Description"), widget=forms.Textarea, required=False) - lenght = forms.IntegerField(label=_(u"Lenght"), required=False) + length = forms.IntegerField(label=_(u"Length"), required=False) width = forms.IntegerField(label=_(u"Width"), required=False) thickness = forms.IntegerField(label=_(u"Thickness"), required=False) depth = forms.IntegerField(label=_(u"Depth"), required=False) @@ -1909,7 +1911,7 @@ record_modification_wizard = RecordModifWizard([ class RecordDeletionWizard(DeletionWizard): model = models.ContextRecord - fields = ['label', 'parcel', 'description', 'lenght', 'width', 'thickness', + fields = ['label', 'parcel', 'description', 'length', 'width', 'thickness', 'depth', 'location', 'datings', 'units', 'has_furniture', 'filling', 'interpretation', 'taq', 'taq_estimated', 'tpq', 'tpq_estimated'] |