Commit 9297a754 authored by Jérome Perrin's avatar Jérome Perrin

pass "plan" workflow transition automatically with workflow method if the user...

pass "plan" workflow transition automatically with workflow method if the user cannot perform user action transtition with his permissions (or if an validation error occurs)


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@4778 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 114a2fc2
......@@ -106,6 +106,7 @@ if sale_invoice.getSimulationState() == \'draft\' : \n
except (ConflictError, RuntimeError), e : raise\n
except Exception, e :\n
LOG(\'Exception in plan_action\', e)\n
if sale_invoice.getSimulationState() == \'draft\' : \n
# call the workflow method, if the user cannot perform this operation.\n
sale_invoice.plan()\n
\n
......@@ -123,44 +124,44 @@ sale_invoice.activate(\n
<item>
<key> <string>_code</string> </key>
<value> <string encoding="base64">YwAAAAAAAAAAAQAAAEAAAABzDQAAAGQBAIQAAFoAAGQAAFMoAgAAAE5jAAAAAA0AAAAYAAAACwAA
AHOrAQAAZAEAawAAbAEAfQIAAXQCAIkAAIcAAGQCAIYAAH0FAHQFAIgAAGQDAIMCAIMAAAF0BQCI
AHPIAQAAZAEAawAAbAEAfQIAAXQCAIkAAIcAAGQCAIYAAH0FAHQFAIgAAGQDAIMCAIMAAAF0BQCI
AABkBACDAgCDAAB9BwB8BQBkBQB0BQCIAABkBgCDAgCDAAAWgwEAAXQFAHwHAGQEAIMCAIMAAH0I
AHQFAHwIAGQHAIMCAIMAAH0JAHQFAIgAAGQIAIMCAGQJAHQFAHwHAGQKAIMCAIMAAGQLAHwJAGQM
AHwJAGQNAHQFAHwHAGQOAIMCAIMAAIMABAF0BQCIAABkDwCDAgCDAABkEABqAgBvlwABeUEAdAUA
AHwJAGQNAHQFAHwHAGQOAIMCAIMAAIMABAF0BQCIAABkDwCDAgCDAABkEABqAgBvtAABeUEAdAUA
dAUAdAUAdAIAZBEAgwIAgwAAZBIAgwIAZBMAgwIAiAAAZBQAZBUAZBYAZBcAZBgAZBkAZBoAgwID
AVdxbwEEfAIAdAkAZgIAagoAbwwA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Y2VfY3Vy
cmVuY3lzDAAAAFJ1bnRpbWVFcnJvcnMBAAAAZXMJAAAARXhjZXB0aW9uKA0AAABzAgAAAGt3cxEA
AABaT0RCLlBPU0V4Y2VwdGlvbnMNAAAAQ29uZmxpY3RFcnJvcnMHAAAAY29udGV4dHMMAAAAc2Fs
ZV9pbnZvaWNlcwMAAABMT0dzCQAAAF9nZXRhdHRyX3MUAAAAcmVsYXRlZF9wYWNraW5nX2xpc3Rz
DQAAAHJlbGF0ZWRfb3JkZXJzDgAAAHByaWNlX2N1cnJlbmN5cwwAAABSdW50aW1lRXJyb3JzAQAA
AGVzCQAAAEV4Y2VwdGlvbigAAAAAKAEAAABzDAAAAHNhbGVfaW52b2ljZXMPAAAAU2NyaXB0IChQ
eXRob24pcy0AAABTYWxlSW52b2ljZVRyYW5zYWN0aW9uX3Bvc3RHZW5lcmF0aW9uQWN0aXZpdHkB
AAAAczIAAAAABQ0CBgIPBA0CEgEaAxIBFQMPAQ8BBgEJARAEGQEMARgBIAMdARABEgEcAhgDEwQM
ASgBAAAAcy0AAABTYWxlSW52b2ljZVRyYW5zYWN0aW9uX3Bvc3RHZW5lcmF0aW9uQWN0aXZpdHko
AQAAAHMtAAAAU2FsZUludm9pY2VUcmFuc2FjdGlvbl9wb3N0R2VuZXJhdGlvbkFjdGl2aXR5KAAA
AAAoAAAAAHMPAAAAU2NyaXB0IChQeXRob24pcwgAAAA8bW9kdWxlPgEAAABzAAAAAA==</string> </value>
</item>
<item>
<key> <string>_filepath</string> </key>
......
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