From 6ae680af7ff8118341cf244b1b41e5e04644ba14 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Thu, 23 May 2019 10:53:43 +0200 Subject: Document generation: better layout for VALUES --- archaeological_context_records/models.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'archaeological_context_records/models.py') diff --git a/archaeological_context_records/models.py b/archaeological_context_records/models.py index f728aef57..b3e4be9f0 100644 --- a/archaeological_context_records/models.py +++ b/archaeological_context_records/models.py @@ -520,12 +520,13 @@ class ContextRecord(BulkUpdatedItem, BaseHistorizedItem, QRCodeItem, GeoItem, def __unicode__(self): return self.short_label - def get_values(self, prefix='', no_base_finds=True): - values = super(ContextRecord, self).get_values(prefix=prefix) + def get_values(self, prefix='', no_values=False, no_base_finds=True): + values = super(ContextRecord, self).get_values(prefix=prefix, + no_values=no_values) if prefix and no_base_finds: return values values[prefix + 'base_finds'] = [ - bf.get_values(prefix=prefix) + bf.get_values(prefix=prefix, no_values=True) for bf in self.base_finds.distinct().all() ] return values -- cgit v1.2.3