diff options
Diffstat (limited to 'archaeological_operations/forms.py')
-rw-r--r-- | archaeological_operations/forms.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/archaeological_operations/forms.py b/archaeological_operations/forms.py index 99bf4b848..f9f1095be 100644 --- a/archaeological_operations/forms.py +++ b/archaeological_operations/forms.py @@ -33,8 +33,8 @@ from django.forms.formsets import formset_factory, DELETION_FIELD_NAME, \ from django.utils.translation import ugettext_lazy as _, pgettext_lazy from django.utils.safestring import mark_safe -from ishtar_common.models import valid_id, PersonType, Person, Town, \ - DocumentTemplate, Organization, OrganizationType, get_current_profile, \ +from ishtar_common.models import valid_id, Person, Town, \ + DocumentTemplate, Organization, get_current_profile, \ person_type_pks_lazy, person_type_pk_lazy, organization_type_pks_lazy, \ organization_type_pk_lazy @@ -1403,8 +1403,8 @@ class DocumentGenerationAdminActForm(forms.Form): def __init__(self, *args, **kwargs): self.document_type = 'O' - if 'operation' in kwargs: - self.document_type = 'O' if kwargs.pop('operation') else 'F' + if 'document_type' in kwargs: + self.document_type = kwargs.pop('document_type') self.obj = None if 'obj' in kwargs: self.obj = kwargs.pop('obj') |