From f5d4b206e43f81bb3c3192faf2b7e73d3f505ff1 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Mon, 26 Mar 2018 18:39:45 +0200 Subject: Finds - discovery date: add a TAQ field (refs #4039) - improve display of discovery date in sheet - better display for textarea field --- archaeological_finds/models_finds.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'archaeological_finds/models_finds.py') diff --git a/archaeological_finds/models_finds.py b/archaeological_finds/models_finds.py index 1f132d3e8..ae3c45579 100644 --- a/archaeological_finds/models_finds.py +++ b/archaeological_finds/models_finds.py @@ -219,8 +219,10 @@ class BaseFind(BulkUpdatedItem, BaseHistorizedItem, OwnPerms): context_record = models.ForeignKey( ContextRecord, related_name='base_finds', verbose_name=_(u"Context Record")) - discovery_date = models.DateField(_(u"Discovery date"), + discovery_date = models.DateField(_(u"Discovery date (exact or TPQ)"), blank=True, null=True) + discovery_date_taq = models.DateField(_(u"Discovery date (TAQ)"), + blank=True, null=True) batch = models.ForeignKey(BatchType, verbose_name=_(u"Batch/object"), blank=True, null=True) index = models.IntegerField(u"Index", default=0) @@ -594,7 +596,10 @@ class Find(BulkUpdatedItem, ValueGetter, BaseHistorizedItem, ImageModel, 'base_finds__topographic_localisation': _(u"Base find - " u"Topographic localisation"), 'base_finds__special_interest': _(u"Base find - Special interest"), - 'base_finds__discovery_date': _(u"Base find - Discovery date"), + 'base_finds__discovery_date': _( + u"Base find - Discovery date (exact or TPQ)"), + 'base_finds__discovery_date_taq': _( + u"Base find - Discovery date (TAQ)"), 'container__cached_label': _(u"Container"), 'datings__period__label': _(u"Periods"), 'material_types__label': _(u"Material types"), @@ -607,7 +612,9 @@ class Find(BulkUpdatedItem, ValueGetter, BaseHistorizedItem, ImageModel, 'base_finds__comment', 'base_finds__description', 'base_finds__topographic_localisation', 'base_finds__special_interest', - 'base_finds__discovery_date'] + 'base_finds__discovery_date', + 'base_finds__discovery_date_taq', + ] ATTRS_EQUIV = {'get_first_base_find': 'base_finds'} # search parameters -- cgit v1.2.3