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

Use a translatable message for "Initialized by Delivery Builder" message.

Don't hardcode wf_id when calling doActionFor in SalePackingList_copyOrderProperties

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@18782 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ed11c8e9
......@@ -65,15 +65,16 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>packing_list = context\n
<value> <string>from Products.ERP5Type.Message import Message\n
\n
packing_list = context\n
\n
# Then, modify state\n
# Modify state\n
packing_list_state = packing_list.getSimulationState()\n
if packing_list_state == "draft":\n
packing_list.portal_workflow.doActionFor(\n
packing_list,\n
\'confirm_action\',\n
comment="Initialized by Delivery Builder")\n
packing_list, \'confirm_action\',\n
comment=Message(\'erp5_ui\', "Initialized by Delivery Builder"))\n
</string> </value>
</item>
<item>
......@@ -123,6 +124,8 @@ if packing_list_state == "draft":\n
<value>
<tuple>
<string>kw</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>context</string>
<string>packing_list</string>
<string>_getattr_</string>
......
......@@ -65,7 +65,9 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>packing_list = context\n
<value> <string>from Products.ERP5Type.Message import Message\n
\n
packing_list = context\n
\n
# First, copy Order properties\n
packing_list.PackingList_copyOrderProperties()\n
......@@ -75,10 +77,8 @@ packing_list_state = packing_list.getSimulationState()\n
\n
if packing_list_state == "draft":\n
packing_list.portal_workflow.doActionFor(\n
packing_list,\n
\'confirm_action\',\n
wf_id=\'packing_list_workflow\',\n
comment="Initialized by Delivery Builder")\n
packing_list, \'confirm_action\',\n
comment=Message(\'erp5_ui\', "Initialized by Delivery Builder"))\n
\n
# First set the packing_list in the building state\n
packing_list.startBuilding()\n
......@@ -127,6 +127,8 @@ packing_list.activate(after_method_id=(\'immediateReindexObject\',\'recursiveImm
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>context</string>
<string>packing_list</string>
<string>_getattr_</string>
......
156
\ No newline at end of file
157
\ 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