diff options
Diffstat (limited to 'archaeological_context_records/forms.py')
-rw-r--r-- | archaeological_context_records/forms.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/archaeological_context_records/forms.py b/archaeological_context_records/forms.py index 40be1b7de..fe6534ea8 100644 --- a/archaeological_context_records/forms.py +++ b/archaeological_context_records/forms.py @@ -62,6 +62,7 @@ from archaeological_operations.forms import ( RecordRelationsForm as OpeRecordRelationsForm, RecordRelationsFormSetBase, ) +from ishtar_common.models import Person from archaeological_operations.models import ( Period, Parcel, @@ -301,6 +302,7 @@ class RecordFormGeneral(CustomForm, ManageOldType): "texture": models.TextureType, "color": models.ColorType, "inclusion": models.InclusionType, + "excavator": Person, } pk = forms.IntegerField(required=False, widget=forms.HiddenInput) operation_id = forms.IntegerField(widget=forms.HiddenInput) @@ -319,6 +321,13 @@ class RecordFormGeneral(CustomForm, ManageOldType): comment = forms.CharField( label=_("General comment"), widget=forms.Textarea, required=False ) + excavator = forms.IntegerField( + label=_("Excavator"), + widget=widgets.JQueryAutoComplete( + reverse_lazy('autocomplete-person'), + associated_model=Person, + new=True), + validators=[valid_id(Person)], required=False) HEADERS["excavation_technic"] = FormHeader(_("Description")) excavation_technic = forms.MultipleChoiceField( label=_("Excavation techniques"), |