Commit bd20ddc9 authored by Jérome Perrin's avatar Jérome Perrin

check existance of methods before calling them, as manage_editActionForm is also called on the standard CMF Actions Tool at erp5/portal_actions/manage_editActionForm


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@3563 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent c806d324
...@@ -209,8 +209,10 @@ class PatchedActionProviderBase(ActionProviderBase): ...@@ -209,8 +209,10 @@ class PatchedActionProviderBase(ActionProviderBase):
a1['category'] = a.getCategory() or 'object' a1['category'] = a.getCategory() or 'object'
a1['visible'] = a.getVisibility() a1['visible'] = a.getVisibility()
a1['action'] = a.getActionExpression() a1['action'] = a.getActionExpression()
a1['icon'] = a.getIconExpression()
a1['condition'] = a.getCondition() a1['condition'] = a.getCondition()
if hasattr(a, 'getIconExpression') :
a1['icon'] = a.getIconExpression()
if hasattr(a, 'getOption') :
a1['optional'] = a.getOption() a1['optional'] = a.getOption()
actions.append(a1) actions.append(a1)
......
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