[Erp5-report] r43491 jm - in /erp5/trunk/products/ERP5: Document/ bootstrap/erp5_core/ToolT...
nobody at svn.erp5.org
nobody at svn.erp5.org
Sat Feb 19 11:30:59 CET 2011
Author: jm
Date: Sat Feb 19 11:30:59 2011
New Revision: 43491
URL: http://svn.erp5.org?rev=43491&view=rev
Log:
Fix 'type_provider_list' attribute of types tool
This fixes TestCrmReports.testEventActivity
Modified:
erp5/trunk/products/ERP5/Document/BusinessTemplate.py
erp5/trunk/products/ERP5/bootstrap/erp5_core/ToolTemplateItem/portal_types.xml
erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision
Modified: erp5/trunk/products/ERP5/Document/BusinessTemplate.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/BusinessTemplate.py?rev=43491&r1=43490&r2=43491&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/BusinessTemplate.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/BusinessTemplate.py [utf8] Sat Feb 19 11:30:59 2011
@@ -587,6 +587,8 @@ class BaseTemplateItem(Implicit, Persist
attr_set.update(('_arg', 'template'))
elif interfaces.IIdGenerator.providedBy(obj):
attr_set.update(('last_max_id_dict', 'last_id_dict'))
+ elif classname == 'Types Tool' and klass.__module__ == 'erp5.portal_type':
+ attr_set.add('type_provider_list')
else:
obj = self.migrateToPortalTypeClass(obj)
@@ -1444,8 +1446,9 @@ class ToolTemplateItem(PathTemplateItem)
portal = context.getPortalObject()
types_tool = portal.portal_types
for type_container_id, obj in self._objects.iteritems():
- if interfaces.ITypeProvider.providedBy(obj) and \
- type_container_id not in types_tool.type_provider_list:
+ if (interfaces.ITypeProvider.providedBy(obj) and
+ type_container_id != types_tool.id and
+ type_container_id not in types_tool.type_provider_list):
types_tool.type_provider_list = tuple(types_tool.type_provider_list) + \
(type_container_id,)
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/ToolTemplateItem/portal_types.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/ToolTemplateItem/portal_types.xml?rev=43491&r1=43490&r2=43491&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/ToolTemplateItem/portal_types.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/ToolTemplateItem/portal_types.xml [utf8] Sat Feb 19 11:30:59 2011
@@ -32,15 +32,6 @@
<key> <string>last_id</string> </key>
<value> <string>2</string> </value>
</item>
- <item>
- <key> <string>type_provider_list</string> </key>
- <value>
- <tuple>
- <string>portal_solvers</string>
- <string>portal_types</string>
- </tuple>
- </value>
- </item>
</dictionary>
</pickle>
</record>
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision?rev=43491&r1=43490&r2=43491&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] Sat Feb 19 11:30:59 2011
@@ -1 +1 @@
-40892
\ No newline at end of file
+40893
\ No newline at end of file
More information about the Erp5-report
mailing list