Commit 299afa30 authored by Sebastien Robin's avatar Sebastien Robin

take care of activate_kw parameter


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@4498 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent a8ec376a
...@@ -51,7 +51,8 @@ class ActiveObject(ExtensionClass.Base): ...@@ -51,7 +51,8 @@ class ActiveObject(ExtensionClass.Base):
security = ClassSecurityInfo() security = ClassSecurityInfo()
def activate(self, activity=DEFAULT_ACTIVITY, active_process=None, passive_commit=0, **kw): def activate(self, activity=DEFAULT_ACTIVITY, active_process=None, passive_commit=0,
activate_kw=None,**kw):
""" """
Reserved Optional parameters Reserved Optional parameters
...@@ -70,6 +71,8 @@ class ActiveObject(ExtensionClass.Base): ...@@ -70,6 +71,8 @@ class ActiveObject(ExtensionClass.Base):
going to be executed going to be executed
""" """
if activate_kw is not None:
kw.update(activate_kw)
activity_tool = getattr(self, 'portal_activities', None) activity_tool = getattr(self, 'portal_activities', None)
if activity_tool is None: return self # Do nothing if no portal_activities if activity_tool is None: return self # Do nothing if no portal_activities
# activate returns an ActiveWrapper # activate returns an ActiveWrapper
......
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