Commit 224309ed authored by Nicolas Dumazet's avatar Nicolas Dumazet

* disable _categories assignment as it seems to break non-migrated instances.

* aggregate all _categories values from accessor holders


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@42849 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 78575795
...@@ -237,7 +237,8 @@ class PortalTypeMetaClass(GhostBaseMetaClass): ...@@ -237,7 +237,8 @@ class PortalTypeMetaClass(GhostBaseMetaClass):
for key, value in attribute_dict.iteritems(): for key, value in attribute_dict.iteritems():
setattr(klass, key, value) setattr(klass, key, value)
klass._categories = base_category_list # XXX disabled
#klass._categories = base_category_list
for interface in interface_list: for interface in interface_list:
classImplements(klass, interface) classImplements(klass, interface)
......
...@@ -287,6 +287,11 @@ def generatePortalTypeClass(site, portal_type_name): ...@@ -287,6 +287,11 @@ def generatePortalTypeClass(site, portal_type_name):
erp5.accessor_holder, erp5.accessor_holder,
property_sheet_tool) property_sheet_tool)
base_category_set = set(base_category_list)
for accessor_holder in accessor_holder_list:
base_category_set.update(accessor_holder._categories)
base_category_list = list(base_category_set)
property_sheet_generating_portal_type_set.remove(portal_type_name) property_sheet_generating_portal_type_set.remove(portal_type_name)
# LOG("ERP5Type.dynamic", INFO, # LOG("ERP5Type.dynamic", INFO,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment