Commit d9a3b275 authored by Bartek Górny's avatar Bartek Górny

some changes, because something changed in the constraint interface

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@11756 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0d5921de
...@@ -72,15 +72,11 @@ ...@@ -72,15 +72,11 @@
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
object = state_change[\'object\']\n object = state_change[\'object\']\n
N_ = object.Base_translateString\n
\n \n
check_result = object.checkConsistency()\n check_result = object.checkConsistency()\n
context.log(check_result)\n
if len(check_result) > 0:\n if len(check_result) > 0:\n
check_type = N_(check_result[0][-1])\n cr=check_result[0]\n
# TODO: use nice url encoding method there instead of replace()\n raise ValidationFailed, "%s : %s" % (cr.message,cr.description)\n
check_details = str(check_result[0][-2]).replace(\'<\', \'&lt;\').replace(\'>\', \'&gt;\')\n
raise ValidationFailed, "%s : %s" % (check_type, check_details)\n
]]></string> </value> ]]></string> </value>
...@@ -131,13 +127,9 @@ if len(check_result) > 0:\n ...@@ -131,13 +127,9 @@ if len(check_result) > 0:\n
<string>_getitem_</string> <string>_getitem_</string>
<string>object</string> <string>object</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>N_</string>
<string>check_result</string> <string>check_result</string>
<string>context</string>
<string>len</string> <string>len</string>
<string>check_type</string> <string>cr</string>
<string>str</string>
<string>check_details</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
412 416
\ No newline at end of file \ No newline at end of file
0.82 0.83
\ 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