[Erp5-report] r43012 nicolas.dumazet - /erp5/trunk/products/ERP5/ERP5Site.py

nobody at svn.erp5.org nobody at svn.erp5.org
Fri Feb 4 09:43:14 CET 2011


Author: nicolas.dumazet
Date: Fri Feb  4 09:43:14 2011
New Revision: 43012

URL: http://svn.erp5.org?rev=43012&view=rev
Log:
Fix initialization of site: do not clear activities on the second call.

addERP5Tool might be clever now, and avoids recreating portal_activities
if it already exists, but the line just after should *not* be run if
the tool already exists, or else we simply clear all activities generating
during BT5 install.

Modified:
    erp5/trunk/products/ERP5/ERP5Site.py

Modified: erp5/trunk/products/ERP5/ERP5Site.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/ERP5Site.py?rev=43012&r1=43011&r2=43012&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/ERP5Site.py [utf8] (original)
+++ erp5/trunk/products/ERP5/ERP5Site.py [utf8] Fri Feb  4 09:43:14 2011
@@ -1621,7 +1621,7 @@ class ERP5Generator(PortalGenerator):
     make sure that we do not put un the queue the full reindexation
     """
     # Add Activity Tool
-    if create_activities:
+    if create_activities and not p.hasObject('portal_activities'):
       addERP5Tool(p, 'portal_activities', 'Activity Tool')
       # Initialize Activities
       p.portal_activities.manageClearActivities(keep=0)



More information about the Erp5-report mailing list