Commit dc1fa864 authored by Nicolas Delaby's avatar Nicolas Delaby

Translate Action Title for Mass workflow Transitions

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@19570 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0e2870ef
...@@ -65,13 +65,14 @@ ...@@ -65,13 +65,14 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>item_list = [(\'\', \'\')]\n <value> <string>translate = context.Base_translateString\n
item_list = [(\'\', \'\')]\n
for action in context.portal_actions.listFilteredActionsFor(brain).get(\'workflow\', []):\n for action in context.portal_actions.listFilteredActionsFor(brain).get(\'workflow\', []):\n
transition = action.get(\'transition\', None)\n transition = action.get(\'transition\', None)\n
if transition is not None:\n if transition is not None:\n
workflow_id = action[\'transition\'].aq_parent.aq_parent.getId()\n workflow_id = action[\'transition\'].aq_parent.aq_parent.getId()\n
if workflow_id == brain.workflow_id:\n if workflow_id == brain.workflow_id:\n
item_list.append((action[\'title\'], \'%s/%s\' % (workflow_id, action[\'id\'])))\n item_list.append((translate(action[\'title\']), \'%s/%s\' % (workflow_id, action[\'id\'])))\n
\n \n
return item_list\n return item_list\n
</string> </value> </string> </value>
...@@ -132,10 +133,11 @@ return item_list\n ...@@ -132,10 +133,11 @@ return item_list\n
<tuple> <tuple>
<string>brain</string> <string>brain</string>
<string>kw</string> <string>kw</string>
<string>item_list</string>
<string>_getiter_</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>translate</string>
<string>item_list</string>
<string>_getiter_</string>
<string>action</string> <string>action</string>
<string>None</string> <string>None</string>
<string>transition</string> <string>transition</string>
......
711 712
\ No newline at end of file \ No newline at end of file
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