diff options
Diffstat (limited to 'archaeological_warehouse/models.py')
| -rw-r--r-- | archaeological_warehouse/models.py | 13 | 
1 files changed, 8 insertions, 5 deletions
| diff --git a/archaeological_warehouse/models.py b/archaeological_warehouse/models.py index 224fe8b21..00500bdcf 100644 --- a/archaeological_warehouse/models.py +++ b/archaeological_warehouse/models.py @@ -34,10 +34,11 @@ from ishtar_common.utils import ugettext_lazy as _, pgettext_lazy  from django.apps import apps  from ishtar_common.data_importer import post_importer_action, pre_importer_action  from ishtar_common.model_managers import ExternalIdManager, UUIDModelManager -from ishtar_common.models import ValueGetter, get_current_profile +from ishtar_common.models import ValueGetter, get_current_profile, HistoryModel  from ishtar_common.models_common import (      GeneralType, -    LightHistorizedItem, +    BaseHistorizedItem, +    HistoricalRecords,      OwnPerms,      Address,      post_save_cache, @@ -834,7 +835,7 @@ class ContainerTree(models.Model):  class Container(      DocumentItem,      Merge, -    LightHistorizedItem, +    BaseHistorizedItem,      CompleteIdentifierItem,      GeoItem,      OwnPerms, @@ -1047,10 +1048,10 @@ class Container(          "documents__associated_file__isnull",          "documents__associated_url__isnull",      ] -    BOOL_FIELDS = LightHistorizedItem.BOOL_FIELDS + ["container_type__stationary"] +    BOOL_FIELDS = BaseHistorizedItem.BOOL_FIELDS + ["container_type__stationary"]      REVERSED_MANY_COUNTED_FIELDS = ["finds__isnull", "finds_ref"] -    ALT_NAMES.update(LightHistorizedItem.ALT_NAMES) +    ALT_NAMES.update(BaseHistorizedItem.ALT_NAMES)      ALT_NAMES.update(DocumentItem.ALT_NAMES)      DYNAMIC_REQUESTS = { @@ -1167,6 +1168,8 @@ class Container(          blank=True,          null=True,      ) +    history_date_deprecated = models.DateTimeField(default=datetime.datetime.now) +    history = HistoricalRecords(bases=[HistoryModel])      DISABLE_POLYGONS = False      MERGE_ATTRIBUTE = "get_merge_key" | 
