Commit 01add7d3 authored by Fabien Morin's avatar Fabien Morin

add translateString

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@24269 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent dc93cbd3
...@@ -56,6 +56,7 @@ ...@@ -56,6 +56,7 @@
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
changed_object = state_change[\'object\']\n changed_object = state_change[\'object\']\n
translateString = changed_object.Base_translateString\n
login = changed_object.getCompanyName().lower()\n login = changed_object.getCompanyName().lower()\n
portal_catalog = changed_object.portal_catalog\n portal_catalog = changed_object.portal_catalog\n
ninea = changed_object.getNinea()\n ninea = changed_object.getNinea()\n
...@@ -66,7 +67,6 @@ from Products.DCWorkflow.DCWorkflow import ValidationFailed\n ...@@ -66,7 +67,6 @@ from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
result = portal_catalog( portal_type=\'Organisation\',\n result = portal_catalog( portal_type=\'Organisation\',\n
vat_code=changed_object.getNinea())\n vat_code=changed_object.getNinea())\n
\n \n
\n
if len(result) > 1:\n if len(result) > 1:\n
msg = "Error : There is more than one company with the NINEA code ${code}"\n msg = "Error : There is more than one company with the NINEA code ${code}"\n
msg = translateString(msg, mapping=dict(code=ninea))\n msg = translateString(msg, mapping=dict(code=ninea))\n
...@@ -126,6 +126,7 @@ if len(result) == 1 and result[0].getObject().getReference():\n ...@@ -126,6 +126,7 @@ if len(result) == 1 and result[0].getObject().getReference():\n
<string>_getitem_</string> <string>_getitem_</string>
<string>changed_object</string> <string>changed_object</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>translateString</string>
<string>login</string> <string>login</string>
<string>portal_catalog</string> <string>portal_catalog</string>
<string>ninea</string> <string>ninea</string>
...@@ -134,7 +135,6 @@ if len(result) == 1 and result[0].getObject().getReference():\n ...@@ -134,7 +135,6 @@ if len(result) == 1 and result[0].getObject().getReference():\n
<string>result</string> <string>result</string>
<string>len</string> <string>len</string>
<string>msg</string> <string>msg</string>
<string>translateString</string>
<string>dict</string> <string>dict</string>
</tuple> </tuple>
</value> </value>
......
414 415
\ 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