diff options
Diffstat (limited to 'archaeological_finds')
-rw-r--r-- | archaeological_finds/models_finds.py | 1 | ||||
-rw-r--r-- | archaeological_finds/templates/ishtar/sheet_basefind.html | 39 |
2 files changed, 25 insertions, 15 deletions
diff --git a/archaeological_finds/models_finds.py b/archaeological_finds/models_finds.py index 3f0ade1df..9d16cb66b 100644 --- a/archaeological_finds/models_finds.py +++ b/archaeological_finds/models_finds.py @@ -267,6 +267,7 @@ class BFBulkView(object): class BaseFind(BulkUpdatedItem, BaseHistorizedItem, OwnPerms): EXTERNAL_ID_KEY = 'base_find_external_id' EXTERNAL_ID_DEPENDENCIES = ['find'] + SLUG = 'basefind' label = models.TextField(_(u"Free ID")) external_id = models.TextField(_(u"External ID"), blank=True, null=True) auto_external_id = models.BooleanField( diff --git a/archaeological_finds/templates/ishtar/sheet_basefind.html b/archaeological_finds/templates/ishtar/sheet_basefind.html index 7ea16fecb..74a2b527e 100644 --- a/archaeological_finds/templates/ishtar/sheet_basefind.html +++ b/archaeological_finds/templates/ishtar/sheet_basefind.html @@ -45,9 +45,31 @@ {% field_flex_full "Description" base_find.description "<pre>" "</pre>" first %} {% field_flex_full "Comment" base_find.comment "<pre>" "</pre>" first %} </div> + <h3>{% trans "Sheet"%}</h3> + <div class='row'> + {% with item.history_creation_date|date:"SHORT_DATETIME_FORMAT" as creation_date %} + {% with item.history_creator.ishtaruser.full_label|add:"<br/><i>"|add:creation_date|add:"</i>" as creator %} + {% field_flex "Created by" creator|safe '' '' first %} + {% endwith %}{% endwith %} + {% if item.history_creation_date != item.last_edition_date %} + {% with item.last_edition_date|date:"SHORT_DATETIME_FORMAT" as edition_date %} + {% with item.history_modifier.ishtaruser.full_label|add:"<br/><i>"|add:edition_date|add:"</i>" as modifier %} + {% trans "Last modified by" as lastmodifiedby_label %} + {% field_flex lastmodifiedby_label modifier|safe '' '' first %} + {% endwith %}{% endwith %} + {% endif %} + </div> + {% if base_find.point_2d or base_find.x or base_find.y or base_find.topographic_localisation %} + {% if base_find.point_2d %} + <div class="clearfix"> + </div> + {% endif %} + <h3>{% trans "Map"%}</h3> + {% with geo_item=base_find %} + {% include "ishtar/blocks/sheet_simple_map.html"%} + {% endwith %} {% if base_find.x or base_find.y or base_find.topographic_localisation %} - <h3>{% trans "Coordinates"%}</h3> <div class='row'> {% field_flex "Point of topographic reference" base_find.topographic_localisation %} <dl class="col-12 d-flex flex-wrap row"> @@ -67,19 +89,6 @@ </dl> </div> {% endif %} - <h3>{% trans "Sheet"%}</h3> - <div class='row'> - {% with item.history_creation_date|date:"SHORT_DATETIME_FORMAT" as creation_date %} - {% with item.history_creator.ishtaruser.full_label|add:"<br/><i>"|add:creation_date|add:"</i>" as creator %} - {% field_flex "Created by" creator|safe '' '' first %} - {% endwith %}{% endwith %} - {% if item.history_creation_date != item.last_edition_date %} - {% with item.last_edition_date|date:"SHORT_DATETIME_FORMAT" as edition_date %} - {% with item.history_modifier.ishtaruser.full_label|add:"<br/><i>"|add:edition_date|add:"</i>" as modifier %} - {% trans "Last modified by" as lastmodifiedby_label %} - {% field_flex lastmodifiedby_label modifier|safe '' '' first %} - {% endwith %}{% endwith %} - {% endif %} - </div> + {% endif %} </div> |