diff options
| author | Étienne Loks <etienne.loks@iggdrasil.net> | 2025-11-05 15:53:30 +0100 |
|---|---|---|
| committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2025-11-05 15:59:34 +0100 |
| commit | 18acf3ef988aeb95a4a1225cee03290ada745fdf (patch) | |
| tree | a5423a58c04d93bf41243b99db9c4955ed54ec72 /archaeological_warehouse/models.py | |
| parent | 8108f0945fe2e02ad763778d394c51784dff5fb4 (diff) | |
| download | Ishtar-18acf3ef988aeb95a4a1225cee03290ada745fdf.tar.bz2 Ishtar-18acf3ef988aeb95a4a1225cee03290ada745fdf.zip | |
🐛 template containers: fix missing values
Diffstat (limited to 'archaeological_warehouse/models.py')
| -rw-r--r-- | archaeological_warehouse/models.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/archaeological_warehouse/models.py b/archaeological_warehouse/models.py index 2cdbee13c..61ba4845e 100644 --- a/archaeological_warehouse/models.py +++ b/archaeological_warehouse/models.py @@ -1944,6 +1944,13 @@ class Container( doc.get_values(prefix=prefix, no_values=True, filtr=filtr, **kwargs) for doc in self.contained_documents_ref.distinct().order_by("index").all() ] + # initialize default values + values.update({ + prefix + "material_types": "", + prefix + "material_types_code": "", + prefix + "find_range_labels": [], + prefix + "find_denominations": [], + }) if not self.finds.count(): return values |
