Commit c92556d5 authored by Vincent Pelletier's avatar Vincent Pelletier

(Aalmost complete) Rewrite of the Mutilated Banknote workflow logic.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13291 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 16cc71af
...@@ -73,48 +73,27 @@ ...@@ -73,48 +73,27 @@
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n from Products.ERP5Type.Message import Message\n
\n \n
ob = state_change[\'object\']\n ob = state_change[\'object\'] \n
state = ob.getSimulationState()\n
# only \'siege\' can do this when no pay back\n
if state == "planned":\n
if ob.getTotalPrice(portal_type="Exchanged Mutilated Banknote Line", fast=0) != 0:\n
# we must be in \'siege\' and we want to pay back for another site\n
if \'siege\' not in ob.getSource() or ob.getSource() == ob.getSourceTrade():\n
msg = Message(domain = "ui", message="You can\'t do this transition.")\n
raise ValidationFailed, (msg,)\n
if ob.getDestinationTotalAssetPrice() != 0:\n
msg = Message(domain = "ui", message="Returned amount must be 0.")\n
raise ValidationFailed, (msg,)\n
\n \n
# check no banknote defined, no pay back\n # check we are in an opened accounting day\n
elif state == "ordered":\n vault = \'%s/surface/caisse_courante/encaisse_des_billets_et_monnaies\' %(ob.getSource(),)\n
if len(ob.objectValues(portal_type=["Exchanged Mutilated Banknote Line", "Outgoing Mutilated Banknote Line"])) != 0:\n date = ob.getStartDate()\n
msg = Message(domain = "ui", message="You can\'t do this transition with exchanged or returned banknote defined.")\n if not ob.Baobab_checkCounterDateOpen(site=vault, date=date):\n
raise ValidationFailed, (msg,)\n msg = Message(domain = "ui", message="Counter Date is not opened")\n
if ob.getDestinationTotalAssetPrice() != 0:\n
msg = Message(domain = "ui", message="Returned amount must be 0.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
\n \n
# check outgoing line, we pay back\n if len(ob.objectValues(portal_type="Outgoing Mutilated Banknote Line")) == 0:\n
elif state == "confirmed":\n
if len(ob.objectValues(portal_type="Outgoing Mutilated Banknote Line")) == 0:\n
msg = Message(domain = "ui", message="You must defined returned banknote.")\n msg = Message(domain = "ui", message="You must defined returned banknote.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
if ob.getDestinationTotalAssetPrice() != ob.getTotalPrice(portal_type="Outgoing Mutilated Banknote Line", fast=0):\n if ob.getDestinationTotalAssetPrice() != ob.getTotalPrice(portal_type="Outgoing Mutilated Banknote Line", fast=0):\n
msg = Message(domain = "ui", message="Returned value different from exchanged value.")\n msg = Message(domain = "ui", message="Returned value different from exchanged value.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
# check we are in an opened accounting day\n # now check balance\n
vault = \'%s/surface/caisse_courante/encaisse_des_billets_et_monnaies\' %(ob.getSource(),)\n resource = ob.CashDelivery_checkCounterInventory(source=vault, portal_type=\'Outgoing Mutilated Banknote Line\', same_source=1)\n
date = ob.getStartDate()\n if resource == 2:\n
if not ob.Baobab_checkCounterDateOpen(site=vault, date=date):\n
msg = Message(domain = "ui", message="Counter Date is not opened")\n
raise ValidationFailed, (msg,)\n
# now check balance\n
resource = ob.CashDelivery_checkCounterInventory(source=vault, portal_type=\'Outgoing Mutilated Banknote Line\', same_source=1)\n
if resource == 2:\n
msg = Message(domain="ui", message="No Returned banknote defined.")\n msg = Message(domain="ui", message="No Returned banknote defined.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
elif resource <> 0 :\n elif resource <> 0 :\n
msg = Message(domain="ui", message="Insufficient Balance.")\n msg = Message(domain="ui", message="Insufficient Balance.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
...@@ -169,11 +148,10 @@ elif state == "confirmed":\n ...@@ -169,11 +148,10 @@ elif state == "confirmed":\n
<string>_getitem_</string> <string>_getitem_</string>
<string>ob</string> <string>ob</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>state</string>
<string>msg</string>
<string>len</string>
<string>vault</string> <string>vault</string>
<string>date</string> <string>date</string>
<string>msg</string>
<string>len</string>
<string>resource</string> <string>resource</string>
</tuple> </tuple>
</value> </value>
......
...@@ -74,30 +74,24 @@ from Products.DCWorkflow.DCWorkflow import ValidationFailed\n ...@@ -74,30 +74,24 @@ from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n from Products.ERP5Type.Message import Message\n
\n \n
ob = state_change[\'object\']\n ob = state_change[\'object\']\n
state = ob.getSimulationState()\n
\n \n
if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n
msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
\n \n
if state == "planned":\n if ob.getDestinationTotalAssetPrice() == 0:\n
if len(ob.objectValues(portal_type=\'Exchanged Mutilated Banknote Line\')) == 0:\n msg = Message(domain = "ui", message="Exchanged amount must be defined on document.")\n
raise ValidationFailed, (msg,)\n
if len(ob.objectValues(portal_type=\'Exchanged Mutilated Banknote Line\')) == 0:\n
msg = Message(domain = "ui", message="You must defined exchanged banknote line.")\n msg = Message(domain = "ui", message="You must defined exchanged banknote line.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
if ob.getTotalPrice(portal_type=\'Exchanged Mutilated Banknote Line\', fast=0) > ob.getTotalPrice(portal_type=\'Incoming Mutilated Banknote Line\', fast=0):\n exchanged_mutilated_banknote_total_price = ob.getTotalPrice(portal_type=\'Exchanged Mutilated Banknote Line\', fast=0)\n
if exchanged_mutilated_banknote_total_price > ob.getTotalPrice(portal_type=\'Incoming Mutilated Banknote Line\', fast=0):\n
msg = Message(domain = "ui", message="Total exchanged greater than total supply.")\n msg = Message(domain = "ui", message="Total exchanged greater than total supply.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
if ob.getTotalPrice(portal_type=\'Exchanged Mutilated Banknote Line\', fast=0) != ob.getDestinationTotalAssetPrice():\n if exchanged_mutilated_banknote_total_price != ob.getDestinationTotalAssetPrice():\n
msg = Message(domain = "ui", message="Exchanged amount differ between line and document.")\n msg = Message(domain = "ui", message="Exchanged amount differ between line and document.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
\n
elif state == "ordered":\n
if ob.getDestinationTotalAssetPrice() == 0:\n
msg = Message(domain = "ui", message="Exchanged amount must be defined on document.")\n
raise ValidationFailed, (msg,)\n
elif len(ob.objectValues(portal_type="Exchanged Mutilated Banknote Line")) != 0:\n
msg = Message(domain = "ui", message="You can\'t have exchanged line defined.")\n
raise ValidationFailed, (msg,)\n
]]></string> </value> ]]></string> </value>
...@@ -150,9 +144,9 @@ elif state == "ordered":\n ...@@ -150,9 +144,9 @@ elif state == "ordered":\n
<string>_getitem_</string> <string>_getitem_</string>
<string>ob</string> <string>ob</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>state</string>
<string>msg</string> <string>msg</string>
<string>len</string> <string>len</string>
<string>exchanged_mutilated_banknote_total_price</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -169,7 +163,7 @@ elif state == "ordered":\n ...@@ -169,7 +163,7 @@ elif state == "ordered":\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>CheckTransitionConfirm</string> </value> <value> <string>CheckTransitionFinish</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
...@@ -72,24 +72,13 @@ ...@@ -72,24 +72,13 @@
from Products.ERP5Type.Message import Message\n from Products.ERP5Type.Message import Message\n
\n \n
ob = state_change[\'object\']\n ob = state_change[\'object\']\n
\n
if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n
msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
\n \n
# check presence of banknote\n # check presence of banknote\n
if len(ob.objectValues()) == 0:\n if len(ob.objectValues(portal_type="Exchanged Mutilated Banknote Line")) != 0:\n
msg = Message(domain = "ui", message="No mutilated banknotes defined.")\n msg = Message(domain = "ui", message="Transition forbidden with exchanged banknote line defined.")\n
raise ValidationFailed, (msg,)\n
\n
# check price defined\n
if ob.getSourceTotalAssetPrice() != ob.getTotalPrice(portal_type=\'Incoming Mutilated Banknote Line\', fast=0):\n
msg = Message(domain = "ui", message="Amont differ between document and line.")\n
raise ValidationFailed, (msg,)\n
\n
# check reporter defined\n
if ob.getSourceDecision() == 0:\n
msg = Message(domain = "ui", message="You must defined reporter.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
</string> </value> </string> </value>
</item> </item>
......
...@@ -72,13 +72,24 @@ ...@@ -72,13 +72,24 @@
from Products.ERP5Type.Message import Message\n from Products.ERP5Type.Message import Message\n
\n \n
ob = state_change[\'object\']\n ob = state_change[\'object\']\n
\n
if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n if not ob.Baobab_checkCounterDateOpen(site=ob.getSource(), date=ob.getStartDate()):\n
msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n msg = Message(domain = "ui", message="Transaction not in the good accounting date")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
\n \n
# check presence of banknote\n # check presence of banknote\n
if len(ob.objectValues(portal_type="Exchanged Mutilated Banknote Line")) != 0:\n if len(ob.objectValues()) == 0:\n
msg = Message(domain = "ui", message="Transition forbidden with exchanged banknote line defined.")\n msg = Message(domain = "ui", message="No mutilated banknotes defined.")\n
raise ValidationFailed, (msg,)\n
\n
# check price defined\n
if ob.getSourceTotalAssetPrice() != ob.getTotalPrice(portal_type=\'Incoming Mutilated Banknote Line\', fast=0):\n
msg = Message(domain = "ui", message="Amont differ between document and line.")\n
raise ValidationFailed, (msg,)\n
\n
# check reporter defined\n
if ob.getSourceDecision() == 0:\n
msg = Message(domain = "ui", message="You must define a reporter.")\n
raise ValidationFailed, (msg,)\n raise ValidationFailed, (msg,)\n
</string> </value> </string> </value>
</item> </item>
...@@ -148,7 +159,7 @@ if len(ob.objectValues(portal_type="Exchanged Mutilated Banknote Line")) != 0:\n ...@@ -148,7 +159,7 @@ if len(ob.objectValues(portal_type="Exchanged Mutilated Banknote Line")) != 0:\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>CheckTransitionOrder</string> </value> <value> <string>CheckTransitionStop</string> </value>
</item> </item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>cancelled</string> </value> <value> <string>archived</string> </value>
</item> </item>
<item> <item>
<key> <string>permission_roles</string> </key> <key> <string>permission_roles</string> </key>
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Cancelled</string> </value> <value> <string>Archived</string> </value>
</item> </item>
<item> <item>
<key> <string>transitions</string> </key> <key> <string>transitions</string> </key>
...@@ -82,9 +82,7 @@ ...@@ -82,9 +82,7 @@
<item> <item>
<key> <string>Add portal content</string> </key> <key> <string>Add portal content</string> </key>
<value> <value>
<tuple> <tuple/>
<string>Manager</string>
</tuple>
</value> </value>
</item> </item>
<item> <item>
...@@ -96,9 +94,7 @@ ...@@ -96,9 +94,7 @@
<item> <item>
<key> <string>Modify portal content</string> </key> <key> <string>Modify portal content</string> </key>
<value> <value>
<tuple> <tuple/>
<string>Manager</string>
</tuple>
</value> </value>
</item> </item>
<item> <item>
......
...@@ -82,9 +82,7 @@ ...@@ -82,9 +82,7 @@
<item> <item>
<key> <string>Add portal content</string> </key> <key> <string>Add portal content</string> </key>
<value> <value>
<tuple> <tuple/>
<string>Manager</string>
</tuple>
</value> </value>
</item> </item>
<item> <item>
...@@ -96,9 +94,7 @@ ...@@ -96,9 +94,7 @@
<item> <item>
<key> <string>Modify portal content</string> </key> <key> <string>Modify portal content</string> </key>
<value> <value>
<tuple> <tuple/>
<string>Manager</string>
</tuple>
</value> </value>
</item> </item>
<item> <item>
......
...@@ -42,8 +42,8 @@ ...@@ -42,8 +42,8 @@
<tuple> <tuple>
<string>delete</string> <string>delete</string>
<string>delete_action</string> <string>delete_action</string>
<string>plan</string> <string>stop</string>
<string>plan_action</string> <string>stop_action</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>confirmed</string> </value> <value> <string>finished</string> </value>
</item> </item>
<item> <item>
<key> <string>permission_roles</string> </key> <key> <string>permission_roles</string> </key>
...@@ -86,7 +86,7 @@ ...@@ -86,7 +86,7 @@
<key> <string>Add portal content</string> </key> <key> <string>Add portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>DestinationAssignor</string> <string>Assignee</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -101,6 +101,7 @@ ...@@ -101,6 +101,7 @@
<key> <string>Modify portal content</string> </key> <key> <string>Modify portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
......
...@@ -34,18 +34,16 @@ ...@@ -34,18 +34,16 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Sent To Validation</string> </value> <value> <string>Sent To Headquarters</string> </value>
</item> </item>
<item> <item>
<key> <string>transitions</string> </key> <key> <string>transitions</string> </key>
<value> <value>
<tuple> <tuple>
<string>confirm</string> <string>archive</string>
<string>confirm_action</string> <string>archive_action</string>
<string>deliver</string> <string>finish</string>
<string>deliver_action</string> <string>finish_action</string>
<string>order</string>
<string>order_action</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -78,9 +76,9 @@ ...@@ -78,9 +76,9 @@
<key> <string>Access contents information</string> </key> <key> <string>Access contents information</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>Auditor</string> <string>Auditor</string>
<string>DestinationAssignor</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -89,7 +87,6 @@ ...@@ -89,7 +87,6 @@
<key> <string>Add portal content</string> </key> <key> <string>Add portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -104,7 +101,6 @@ ...@@ -104,7 +101,6 @@
<key> <string>Modify portal content</string> </key> <key> <string>Modify portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -113,9 +109,9 @@ ...@@ -113,9 +109,9 @@
<key> <string>View</string> </key> <key> <string>View</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>Auditor</string> <string>Auditor</string>
<string>DestinationAssignor</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
......
...@@ -18,13 +18,19 @@ ...@@ -18,13 +18,19 @@
<none/> <none/>
</value> </value>
</item> </item>
<item>
<key> <string>_owner</string> </key>
<value>
<none/>
</value>
</item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>ordered</string> </value> <value> <string>stopped</string> </value>
</item> </item>
<item> <item>
<key> <string>permission_roles</string> </key> <key> <string>permission_roles</string> </key>
...@@ -34,16 +40,18 @@ ...@@ -34,16 +40,18 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Sent To Headquarters</string> </value> <value> <string>Stopped</string> </value>
</item> </item>
<item> <item>
<key> <string>transitions</string> </key> <key> <string>transitions</string> </key>
<value> <value>
<tuple> <tuple>
<string>confirm</string> <string>archive</string>
<string>confirm_action</string> <string>archive_action</string>
<string>deliver</string> <string>finish</string>
<string>deliver_action</string> <string>finish_action</string>
<string>plan</string>
<string>plan_action</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -76,7 +84,6 @@ ...@@ -76,7 +84,6 @@
<key> <string>Access contents information</string> </key> <key> <string>Access contents information</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>Auditor</string> <string>Auditor</string>
<string>Manager</string> <string>Manager</string>
...@@ -87,6 +94,7 @@ ...@@ -87,6 +94,7 @@
<key> <string>Add portal content</string> </key> <key> <string>Add portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignor</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -101,7 +109,7 @@ ...@@ -101,7 +109,7 @@
<key> <string>Modify portal content</string> </key> <key> <string>Modify portal content</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string> <string>Assignor</string>
<string>Manager</string> <string>Manager</string>
</tuple> </tuple>
</value> </value>
...@@ -110,7 +118,6 @@ ...@@ -110,7 +118,6 @@
<key> <string>View</string> </key> <key> <string>View</string> </key>
<value> <value>
<tuple> <tuple>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>Auditor</string> <string>Auditor</string>
<string>Manager</string> <string>Manager</string>
......
...@@ -46,11 +46,11 @@ ...@@ -46,11 +46,11 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>confirm</string> </value> <value> <string>archive</string> </value>
</item> </item>
<item> <item>
<key> <string>new_state_id</string> </key> <key> <string>new_state_id</string> </key>
<value> <string>confirmed</string> </value> <value> <string>archived</string> </value>
</item> </item>
<item> <item>
<key> <string>script_name</string> </key> <key> <string>script_name</string> </key>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Sent To Counter</string> </value> <value> <string>Archive</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string> <string>Assignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -24,15 +24,15 @@ ...@@ -24,15 +24,15 @@
</item> </item>
<item> <item>
<key> <string>actbox_name</string> </key> <key> <string>actbox_name</string> </key>
<value> <string>Cancel</string> </value> <value> <string>Archive</string> </value>
</item> </item>
<item> <item>
<key> <string>actbox_url</string> </key> <key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=cancel_action</string> </value> <value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=archive_action</string> </value>
</item> </item>
<item> <item>
<key> <string>after_script_name</string> </key> <key> <string>after_script_name</string> </key>
<value> <string>cancel</string> </value> <value> <string>archive</string> </value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>cancel_action</string> </value> <value> <string>archive_action</string> </value>
</item> </item>
<item> <item>
<key> <string>new_state_id</string> </key> <key> <string>new_state_id</string> </key>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Cancel Action</string> </value> <value> <string>Archive Action</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -84,9 +84,7 @@ ...@@ -84,9 +84,7 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>DestinationAssignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
<item> <item>
<key> <string>guard</string> </key> <key> <string>guard</string> </key>
<value> <value>
<none/> <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value> </value>
</item> </item>
<item> <item>
...@@ -73,4 +73,28 @@ ...@@ -73,4 +73,28 @@
</dictionary> </dictionary>
</pickle> </pickle>
</record> </record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<tuple>
<string>Products.DCWorkflow.Guard</string>
<string>Guard</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>roles</string> </key>
<value>
<tuple>
<string>Manager</string>
<string>Assignor</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData> </ZopeData>
...@@ -84,7 +84,6 @@ ...@@ -84,7 +84,6 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>DestinationAssignor</string>
<string>Assignee</string> <string>Assignee</string>
</tuple> </tuple>
</value> </value>
......
...@@ -79,12 +79,17 @@ ...@@ -79,12 +79,17 @@
</pickle> </pickle>
<pickle> <pickle>
<dictionary> <dictionary>
<item>
<key> <string>expr</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item> <item>
<key> <string>roles</string> </key> <key> <string>roles</string> </key>
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>DestinationAssignor</string>
<string>Assignee</string> <string>Assignee</string>
</tuple> </tuple>
</value> </value>
...@@ -92,4 +97,23 @@ ...@@ -92,4 +97,23 @@
</dictionary> </dictionary>
</pickle> </pickle>
</record> </record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<tuple>
<string>Products.CMFCore.Expression</string>
<string>Expression</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: "siege" not in here.getSource("")</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData> </ZopeData>
...@@ -46,11 +46,11 @@ ...@@ -46,11 +46,11 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>cancel</string> </value> <value> <string>finish</string> </value>
</item> </item>
<item> <item>
<key> <string>new_state_id</string> </key> <key> <string>new_state_id</string> </key>
<value> <string>cancelled</string> </value> <value> <string>finished</string> </value>
</item> </item>
<item> <item>
<key> <string>script_name</string> </key> <key> <string>script_name</string> </key>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Cancel</string> </value> <value> <string>Finish</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -84,9 +84,7 @@ ...@@ -84,9 +84,7 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string>
<string>Assignor</string> <string>Assignor</string>
<string>DestinationAssignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -28,11 +28,11 @@ ...@@ -28,11 +28,11 @@
</item> </item>
<item> <item>
<key> <string>actbox_url</string> </key> <key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=confirm_action</string> </value> <value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=finish_action</string> </value>
</item> </item>
<item> <item>
<key> <string>after_script_name</string> </key> <key> <string>after_script_name</string> </key>
<value> <string>confirm</string> </value> <value> <string>finish</string> </value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>confirm_action</string> </value> <value> <string>finish_action</string> </value>
</item> </item>
<item> <item>
<key> <string>new_state_id</string> </key> <key> <string>new_state_id</string> </key>
...@@ -54,11 +54,11 @@ ...@@ -54,11 +54,11 @@
</item> </item>
<item> <item>
<key> <string>script_name</string> </key> <key> <string>script_name</string> </key>
<value> <string>CheckTransitionConfirm</string> </value> <value> <string>CheckTransitionFinish</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Sent To Counter Action</string> </value> <value> <string>Finish Action</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string> <string>Assignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.DCWorkflow.Transitions</string>
<string>TransitionDefinition</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>__ac_local_roles__</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>actbox_name</string> </key>
<value> <string>Send To Headquarters</string> </value>
</item>
<item>
<key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=order_action</string> </value>
</item>
<item>
<key> <string>after_script_name</string> </key>
<value> <string>order</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>guard</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>order_action</string> </value>
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>script_name</string> </key>
<value> <string>CheckTransitionOrder</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Send To Validation Action</string> </value>
</item>
<item>
<key> <string>trigger_type</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<tuple>
<string>Products.DCWorkflow.Guard</string>
<string>Guard</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>expr</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>roles</string> </key>
<value>
<tuple>
<string>Manager</string>
<string>Assignee</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<tuple>
<string>Products.CMFCore.Expression</string>
<string>Expression</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: "siege" not in here.getSource("")</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Send To Validation</string> </value> <value> <string>Plan</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</item> </item>
<item> <item>
<key> <string>actbox_name</string> </key> <key> <string>actbox_name</string> </key>
<value> <string>Send To Validation</string> </value> <value> <string>Send To Headquarters</string> </value>
</item> </item>
<item> <item>
<key> <string>actbox_url</string> </key> <key> <string>actbox_url</string> </key>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Send To Validation Action</string> </value> <value> <string>Plan Action</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -79,6 +79,12 @@ ...@@ -79,6 +79,12 @@
</pickle> </pickle>
<pickle> <pickle>
<dictionary> <dictionary>
<item>
<key> <string>expr</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item> <item>
<key> <string>roles</string> </key> <key> <string>roles</string> </key>
<value> <value>
...@@ -91,4 +97,23 @@ ...@@ -91,4 +97,23 @@
</dictionary> </dictionary>
</pickle> </pickle>
</record> </record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<tuple>
<string>Products.CMFCore.Expression</string>
<string>Expression</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: "siege" not in here.getSource("")</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData> </ZopeData>
...@@ -46,11 +46,11 @@ ...@@ -46,11 +46,11 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>order</string> </value> <value> <string>stop</string> </value>
</item> </item>
<item> <item>
<key> <string>new_state_id</string> </key> <key> <string>new_state_id</string> </key>
<value> <string>ordered</string> </value> <value> <string>stopped</string> </value>
</item> </item>
<item> <item>
<key> <string>script_name</string> </key> <key> <string>script_name</string> </key>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Order</string> </value> <value> <string>Stop</string> </value>
</item> </item>
<item> <item>
<key> <string>trigger_type</string> </key> <key> <string>trigger_type</string> </key>
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string> <string>Assignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.DCWorkflow.Transitions</string>
<string>TransitionDefinition</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>__ac_local_roles__</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>actbox_name</string> </key>
<value> <string>Send To Validation</string> </value>
</item>
<item>
<key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/BaseWorkflow_viewWorkflowActionDialog?workflow_action=stop_action</string> </value>
</item>
<item>
<key> <string>after_script_name</string> </key>
<value> <string>stop</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>guard</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>stop_action</string> </value>
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>script_name</string> </key>
<value> <string>CheckTransitionStop</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Stop action</string> </value>
</item>
<item>
<key> <string>trigger_type</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<tuple>
<string>Products.DCWorkflow.Guard</string>
<string>Guard</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>roles</string> </key>
<value>
<tuple>
<string>Manager</string>
<string>Assignor</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<key> <string>actbox_url</string> </key> <key> <string>actbox_url</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&reset=1 Base_viewWorklist?simulation_state=finished&portal_type=Mutilated Banknote&reset=1
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -46,7 +46,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese ...@@ -46,7 +46,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>confirmed</string> </value> <value> <string>finished</string> </value>
</item> </item>
<item> <item>
<key> <string>var_matches</string> </key> <key> <string>var_matches</string> </key>
...@@ -74,7 +74,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese ...@@ -74,7 +74,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>DestinationAssignor</string> <string>Assignee</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -109,7 +109,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese ...@@ -109,7 +109,7 @@ Base_viewWorklist?simulation_state=confirmed&portal_type=Mutilated Banknote&rese
<key> <string>simulation_state</string> </key> <key> <string>simulation_state</string> </key>
<value> <value>
<tuple> <tuple>
<string>confirmed</string> <string>finished</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<key> <string>actbox_url</string> </key> <key> <string>actbox_url</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset=1 Base_viewWorklist?simulation_state=planned&portal_type=Mutilated Banknote&reset=1
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -46,7 +46,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset= ...@@ -46,7 +46,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset=
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>ordered</string> </value> <value> <string>planned</string> </value>
</item> </item>
<item> <item>
<key> <string>var_matches</string> </key> <key> <string>var_matches</string> </key>
...@@ -74,7 +74,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset= ...@@ -74,7 +74,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset=
<value> <value>
<tuple> <tuple>
<string>Manager</string> <string>Manager</string>
<string>Assignee</string> <string>DestinationAssignor</string>
</tuple> </tuple>
</value> </value>
</item> </item>
...@@ -109,7 +109,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset= ...@@ -109,7 +109,7 @@ Base_viewWorklist?simulation_state=ordered&portal_type=Mutilated Banknote&reset=
<key> <string>simulation_state</string> </key> <key> <string>simulation_state</string> </key>
<value> <value>
<tuple> <tuple>
<string>ordered</string> <string>planned</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
202 207
\ 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