summaryrefslogtreecommitdiff
path: root/ishtar_common/models_imports.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2022-03-16 18:04:57 +0100
committerÉtienne Loks <etienne.loks@iggdrasil.net>2022-12-12 12:21:00 +0100
commitaaf752eb46b1964f261979c91e424309717b8868 (patch)
treefdd4a4db0dc83330d09944049aebc8062441b505 /ishtar_common/models_imports.py
parent95b1566b4019b8b61a8e1fa8c2bef8b9fcacf273 (diff)
downloadIshtar-aaf752eb46b1964f261979c91e424309717b8868.tar.bz2
Ishtar-aaf752eb46b1964f261979c91e424309717b8868.zip
Geodata: form to create GIS import
Diffstat (limited to 'ishtar_common/models_imports.py')
-rw-r--r--ishtar_common/models_imports.py8
1 files changed, 8 insertions, 0 deletions
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,