summaryrefslogtreecommitdiff
path: root/archaeological_finds/forms.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2018-05-23 12:58:38 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2018-06-12 08:49:06 +0200
commit88c9aeaeafd9bc77decbf0982be0fd9d20fd3993 (patch)
tree1e9650dcdfb9359e6c1a70031f7705d18700374d /archaeological_finds/forms.py
parentb40361b7c1b8e98690b1f4cf6b5154f8b22395ff (diff)
downloadIshtar-88c9aeaeafd9bc77decbf0982be0fd9d20fd3993.tar.bz2
Ishtar-88c9aeaeafd9bc77decbf0982be0fd9d20fd3993.zip
Wizards - JSON fields: inlines for custom form in admin pages (refs #4089)
Diffstat (limited to 'archaeological_finds/forms.py')
-rw-r--r--archaeological_finds/forms.py14
1 files changed, 10 insertions, 4 deletions
diff --git a/archaeological_finds/forms.py b/archaeological_finds/forms.py
index 44d883b0f..8cb2fd0aa 100644
--- a/archaeological_finds/forms.py
+++ b/archaeological_finds/forms.py
@@ -43,7 +43,7 @@ from ishtar_common.forms import FormSet, FloatField, \
ManageOldType, FieldType, IshtarForm, FormHeader
from ishtar_common.forms_common import get_town_field, \
- SourceSelect, CustomForm, BaseImageForm, BaseImageFormset
+ SourceSelect, CustomForm, BaseImageForm, BaseImageFormset, SourceForm
from ishtar_common.utils import convert_coordinates_to_point
from ishtar_common import widgets
from bootstrap_datepicker.widgets import DatePicker
@@ -63,7 +63,8 @@ from archaeological_finds.forms_treatments import TreatmentSelect, \
AdministrativeActTreatmentFileModifForm, SourceTreatmentFormSelection, \
SourceTreatmentFileFormSelection, TreatmentSourceFormSelection, \
TreatmentFileSourceFormSelection, DashboardForm as DashboardTreatmentForm, \
- DashboardTreatmentFileForm, TreatmentImagesFormset
+ DashboardTreatmentFileForm, TreatmentImagesFormset, \
+ TreatmentFileSourceForm, TreatmentSourceForm
__all__ = [
'TreatmentSelect', 'TreatmentFormSelection', 'BaseTreatmentForm',
@@ -78,7 +79,8 @@ __all__ = [
'AdministrativeActTreatmentFileModifForm', 'SourceTreatmentFormSelection',
'SourceTreatmentFileFormSelection', 'TreatmentSourceFormSelection',
'TreatmentFileSourceFormSelection', 'DashboardTreatmentForm',
- 'DashboardTreatmentFileForm',
+ 'DashboardTreatmentFileForm', 'TreatmentSourceForm',
+ 'TreatmentFileSourceForm',
'RecordFormSelection', 'FindForm', 'DateForm', 'DatingFormSet',
'PreservationForm', 'ImagesFormset',
'FindSelect', 'FindFormSelection', 'FindFormSelectionWarehouseModule',
@@ -89,7 +91,7 @@ __all__ = [
'FindDeletionForm', 'UpstreamFindFormSelection', 'SourceFindFormSelection',
'FindSourceSelect', 'FindSourceFormSelection', 'NewFindBasketForm',
'SelectFindBasketForm', 'DeleteFindBasketForm', 'FindBasketAddItemForm',
- 'TreatmentImagesFormset'
+ 'TreatmentImagesFormset', 'FindSourceForm'
]
logger = logging.getLogger(__name__)
@@ -864,3 +866,7 @@ class FindBasketAddItemForm(forms.Form):
raise PermissionDenied
basket.items.add(item)
return basket
+
+
+class FindSourceForm(SourceForm):
+ form_slug = "findsource-general"