From 6f7d46f75a2fd065aa7e468c7da01c697fc6ad30 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com>
Date: Fri, 16 Oct 2009 11:16:54 +0000
Subject: [PATCH] disallow transitions if the transaction is divergent

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@29748 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../accounting_workflow/transitions/deliver_action.xml          | 2 +-
 .../accounting_workflow/transitions/stop_action.xml             | 2 +-
 bt5/erp5_accounting/bt/revision                                 | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/deliver_action.xml b/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/deliver_action.xml
index fb08a56b2c..c2fd666b94 100644
--- a/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/deliver_action.xml
+++ b/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/deliver_action.xml
@@ -95,7 +95,7 @@
       <dictionary>
         <item>
             <key> <string>text</string> </key>
-            <value> <string>python: here.getProperty(\'causality_state\', \'default\') != \'building\'</string> </value>
+            <value> <string>python: here.getProperty(\'causality_state\', \'default\') not in (\'building\', \'diverged\')</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/stop_action.xml b/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/stop_action.xml
index 51ecf351bd..edf1fe6a99 100644
--- a/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/stop_action.xml
+++ b/bt5/erp5_accounting/WorkflowTemplateItem/portal_workflow/accounting_workflow/transitions/stop_action.xml
@@ -96,7 +96,7 @@
       <dictionary>
         <item>
             <key> <string>text</string> </key>
-            <value> <string>python: here.getProperty(\'causality_state\', \'default\') != \'building\'</string> </value>
+            <value> <string>python: here.getProperty(\'causality_state\', \'default\') not in (\'building\', \'diverged\')</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_accounting/bt/revision b/bt5/erp5_accounting/bt/revision
index 7cebf7db5f..2478c955ec 100644
--- a/bt5/erp5_accounting/bt/revision
+++ b/bt5/erp5_accounting/bt/revision
@@ -1 +1 @@
-1001
\ No newline at end of file
+1003
\ No newline at end of file
-- 
2.30.9