From 9f08d76f864ba904e0d77549114e56052f3b4ea7 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Wed, 16 Mar 2022 18:04:57 +0100 Subject: Geodata: form to create GIS import --- ishtar_common/models_imports.py | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'ishtar_common/models_imports.py') diff --git a/ishtar_common/models_imports.py b/ishtar_common/models_imports.py index 799b3aab9..85b3473f9 100644 --- a/ishtar_common/models_imports.py +++ b/ishtar_common/models_imports.py @@ -119,6 +119,12 @@ class ImporterTypeManager(models.Manager): return self.get(slug=slug) +IMPORT_TYPES = ( + ("tab", "Table"), + ("gis", _("GIS")), +) + + class ImporterType(models.Model): """ Description of a table to be mapped with ishtar database @@ -129,6 +135,8 @@ class ImporterType(models.Model): description = models.CharField( _("Description"), blank=True, null=True, max_length=500 ) + type = models.CharField(_("Type"), max_length=3, choices=IMPORT_TYPES, + default='tab') users = models.ManyToManyField("IshtarUser", verbose_name=_("Users"), blank=True) associated_models = models.ForeignKey( ImporterModel, -- cgit v1.2.3