[Erp5-report] r17822 - /erp5/trunk/products/ERP5Type/Base.py

nobody at svn.erp5.org nobody at svn.erp5.org
Tue Nov 27 14:50:55 CET 2007


Author: nicolas
Date: Tue Nov 27 14:50:55 2007
New Revision: 17822

URL: http://svn.erp5.org?rev=17822&view=rev
Log:
Call reindex after security update

Modified:
    erp5/trunk/products/ERP5Type/Base.py

Modified: erp5/trunk/products/ERP5Type/Base.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/Base.py?rev=17822&r1=17821&r2=17822&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/Base.py (original)
+++ erp5/trunk/products/ERP5Type/Base.py Tue Nov 27 14:50:55 2007
@@ -3100,13 +3100,15 @@
 
   security.declareProtected(Permissions.ManagePortal,
                             'updateRoleMappingsFor')
-  def updateRoleMappingsFor(self, wf_id,**kw):
+  def updateRoleMappingsFor(self, wf_id, **kw):
     """
     Update security policy according to workflow settings given by wf_id
     """
     workflow = self.portal_workflow.getWorkflowById(wf_id)
     if workflow is not None:
-      workflow.updateRoleMappingsFor(self)
+      changed = workflow.updateRoleMappingsFor(self)
+      if changed:
+        self.reindexObjectSecurity()
 
   # Template Management
   security.declareProtected(Permissions.View, 'getDocumentTemplateList')




More information about the Erp5-report mailing list