diff --git a/product/ERP5/Document/BusinessTemplate.py b/product/ERP5/Document/BusinessTemplate.py index f8825b022d3628dcb2adc7aabcc36d31ff0fb6d4..5f3be5e27cc0d2e74b760f31710949484b37cb3a 100644 --- a/product/ERP5/Document/BusinessTemplate.py +++ b/product/ERP5/Document/BusinessTemplate.py @@ -874,7 +874,7 @@ class ObjectTemplateItem(BaseTemplateItem): subobjects_dict = self._backupObject(action, trashbin, container_path, object_id) # in case of portal types, we want to keep some properties - if getattr(old_obj, 'meta_type', None) == 'ERP5 Type Information': + if getattr(old_obj, 'meta_type', None) == 'ERP5 Base Type': for attr in ('allowed_content_type_list', 'hidden_content_type_list', 'property_sheet_list', diff --git a/product/ERP5Type/Base.py b/product/ERP5Type/Base.py index 1cfb578540781bbf6558d39ea29d11b32b6bd702..cc06aa79e3a029ab2e648321e471ff281b4ad325 100644 --- a/product/ERP5Type/Base.py +++ b/product/ERP5Type/Base.py @@ -936,8 +936,8 @@ class Base( CopyContainer, #LOG( "Create createRelatedValueAccessors %s" % bid,0,'') createRelatedValueAccessors(property_holder, bid) generated_bid[bid] = 1 - for ptype in portal_types.objectValues('ERP5 Type Information') : - for bid in ptype.base_category_list : + for ptype in portal_types.objectValues(): + for bid in ptype.getTypeBaseCategoryList(): if bid not in generated_bid : createRelatedValueAccessors(property_holder, bid) generated_bid[bid] = 1