diff options
-rw-r--r-- | ishtar_common/data_importer.py | 9 | ||||
-rw-r--r-- | ishtar_common/models.py | 3 |
2 files changed, 11 insertions, 1 deletions
diff --git a/ishtar_common/data_importer.py b/ishtar_common/data_importer.py index 34f8ebec8..09ef64c26 100644 --- a/ishtar_common/data_importer.py +++ b/ishtar_common/data_importer.py @@ -1180,6 +1180,15 @@ class Importer(object): # contruct many dict for each values default_dict = {} + + # # get default values + p = [attribute] + if c_path: + p = list(c_path) + p + p = tuple(p) + if p in self._defaults: + for k in self._defaults[p]: + default_dict[k] = self._defaults[p][k] # # init with simple values that will be duplicated for key in val.keys(): if type(val[key]) not in (list, tuple): diff --git a/ishtar_common/models.py b/ishtar_common/models.py index c657f532d..f720dc5ab 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -1539,7 +1539,8 @@ TARGET_MODELS = [ ('archaeological_finds.models.PreservationType', _(u"Preservation type")), ('archaeological_finds.models.ObjectType', _(u"Object type")), ('archaeological_context_records.models.IdentificationType', - _("Identification type")) + _("Identification type")), + ('SupportType', _(u"Support type")), ] TARGET_MODELS_KEYS = [tm[0] for tm in TARGET_MODELS] |