diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-04-05 11:33:54 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-04-05 11:33:54 +0200 |
commit | 75e4fda871103f74e2aaad5ad663a3a734108a80 (patch) | |
tree | 21976a27b67c98aa1a79a63f190d06dd489b89ec /archaeological_finds | |
parent | 00d53a94deb9e7bcd232ef481fdac30269fc76d7 (diff) | |
download | Ishtar-75e4fda871103f74e2aaad5ad663a3a734108a80.tar.bz2 Ishtar-75e4fda871103f74e2aaad5ad663a3a734108a80.zip |
Warehouse sheet: provide statistics (refs #3398)
- Number of finds (total and by places)
- Number of container (total and by places)
Diffstat (limited to 'archaeological_finds')
-rw-r--r-- | archaeological_finds/models_finds.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/archaeological_finds/models_finds.py b/archaeological_finds/models_finds.py index 3785267b2..52601c896 100644 --- a/archaeological_finds/models_finds.py +++ b/archaeological_finds/models_finds.py @@ -37,7 +37,6 @@ from archaeological_operations.models import AdministrativeAct from archaeological_context_records.models import ContextRecord, Dating from ishtar_common.models import PRIVATE_FIELDS, SpatialReferenceSystem -from archaeological_warehouse.models import Container, Collection class MaterialType(GeneralType): @@ -637,7 +636,8 @@ class Find(BaseHistorizedItem, ImageModel, OwnPerms, ShortMenuItem): datings = models.ManyToManyField(Dating, verbose_name=_(u"Dating"), related_name='find') container = models.ForeignKey( - Container, verbose_name=_(u"Container"), blank=True, null=True, + "archaeological_warehouse.Container", verbose_name=_(u"Container"), + blank=True, null=True, related_name='finds', on_delete=models.SET_NULL) is_complete = models.NullBooleanField(_(u"Is complete?"), blank=True, null=True) @@ -671,8 +671,8 @@ class Find(BaseHistorizedItem, ImageModel, OwnPerms, ShortMenuItem): estimated_value = models.FloatField(_(u"Estimated value"), blank=True, null=True) collection = models.ForeignKey( - Collection, verbose_name=_(u"Collection"), blank=True, null=True, - related_name='finds', on_delete=models.SET_NULL) + "archaeological_warehouse.Collection", verbose_name=_(u"Collection"), + blank=True, null=True, related_name='finds', on_delete=models.SET_NULL) cached_label = models.TextField(_(u"Cached name"), null=True, blank=True) history = HistoricalRecords() BASKET_MODEL = FindBasket |