diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2019-02-14 16:31:17 +0100 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2019-04-24 19:38:56 +0200 |
commit | 265d0180cc945281a93efc2f1278959594727e57 (patch) | |
tree | 58d4f80dd68b4ee19444a4cfda604e6665af6da8 /ishtar_common/models.py | |
parent | 1802bffb4d452550e9349875aeee81db8d030b44 (diff) | |
download | Ishtar-265d0180cc945281a93efc2f1278959594727e57.tar.bz2 Ishtar-265d0180cc945281a93efc2f1278959594727e57.zip |
Sheet operation: display map
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r-- | ishtar_common/models.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 8c421bac7..8d3d5df9a 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -1613,6 +1613,13 @@ class DocumentItem(object): class GeoItem(object): + GEO_SOURCE = ('T', _(u"Town")), ('P', _(u"Precise")) + + def geo_point_source(self): + if not self.point_source: + return "" + return dict(self.GEO_SOURCE)[self.point_source] + def _geojson_serialize(self, geom_attr): if not hasattr(self, geom_attr): return "" |