Commit f046c7d3 authored by Aurel's avatar Aurel
Browse files

2006-06-11 aurel

* remove money deposit transfer
* ordered is state of future inventory
* use state_change['object'] in wf script

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@14761 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f7072efd
......@@ -134,9 +134,6 @@
<portal_type id="Money Deposit Rendering">
<item>Cash Delivery Line</item>
</portal_type>
<portal_type id="Money Deposit Transfer">
<item>Cash Delivery Line</item>
</portal_type>
<portal_type id="Mutilated Banknote">
<item>Outgoing Mutilated Banknote Line</item>
<item>Exchanged Mutilated Banknote Line</item>
......
......@@ -154,10 +154,6 @@
<item>Price</item>
<item>Amount</item>
</portal_type>
<portal_type id="Money Deposit Transfer">
<item>Price</item>
<item>Amount</item>
</portal_type>
<portal_type id="Mutilated Banknote">
<item>Amount</item>
<item>Price</item>
......
......@@ -99,10 +99,6 @@
<type>Money Deposit Rendering</type>
<workflow>money_deposit_rendering_workflow, edit_workflow</workflow>
</chain>
<chain>
<type>Money Deposit Transfer</type>
<workflow>edit_workflow, money_deposit_transfer_workflow</workflow>
</chain>
<chain>
<type>Mutilated Banknote</type>
<workflow>edit_workflow, mutilated_banknote_workflow</workflow>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -68,7 +68,7 @@
<value> <string>from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
\n
caisse = transaction.getSource()\n
\n
......@@ -168,8 +168,9 @@ if incoming_total != outgoing_total:\n
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>caisse</string>
<string>msg</string>
<string>resource_one</string>
......
......@@ -65,7 +65,9 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string># check that we don\'t have both incoming and outgoing line on the document\n
<value> <string encoding="cdata"><![CDATA[
# check that we don\'t have both incoming and outgoing line on the document\n
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
\n
......@@ -97,7 +99,16 @@ elif len(in_list) == 0 and len(out_list) == 0:\n
elif (in_price != 0 and in_price != price) or (out_price != 0 and out_price != price):\n
msg = Message(domain = "ui", message="Price differs between document and resource.")\n
raise ValidationFailed, (msg,)\n
</string> </value>
\n
if out_price != 0:\n
#resource = txn.CashDelivery_checkCounterInventory(source=vault, portal_type=\'Outgoing Cash Incident Line\')\n
resource = txn.CashDelivery_checkCounterInventory(source=vault, portal_type=\'Outgoing Cash Incident Line\')\n
if resource <> 0 :\n
msg = Message(domain="ui", message="Insufficient Balance.")\n
raise ValidationFailed, (msg,)\n
]]></string> </value>
</item>
<item>
<key> <string>_code</string> </key>
......@@ -155,6 +166,7 @@ elif (in_price != 0 and in_price != price) or (out_price != 0 and out_price != p
<string>in_price</string>
<string>out_price</string>
<string>len</string>
<string>resource</string>
</tuple>
</value>
</item>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -68,7 +68,7 @@
<value> <string>from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
\n
vaultDestination = transaction.getDestination()\n
\n
......@@ -130,8 +130,9 @@ if not transaction.Baobab_checkCounterDateOpen(site=vaultDestination, date=trans
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>vaultDestination</string>
<string>msg</string>
</tuple>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -70,7 +70,7 @@
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
\n
vault = transaction.getSource()\n
vaultDestination = transaction.getDestination()\n
......@@ -162,13 +162,13 @@ elif resource <> 0 :\n
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>vault</string>
<string>vaultDestination</string>
<string>vliste</string>
<string>len</string>
<string>_getitem_</string>
<string>portal_type_with_no_space</string>
<string>getattr</string>
<string>None</string>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -53,7 +53,9 @@
<item>
<key> <string>type_list</string> </key>
<value>
<tuple/>
<tuple>
<string>future_inventory</string>
</tuple>
</value>
</item>
</dictionary>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -69,7 +69,7 @@
from Products.ERP5Type.Message import Message\n
\n
# Purchase Transaction .\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
# Get inventory\n
vault = transaction.getSource()\n
resource = transaction.CashDelivery_checkCounterInventory(source=vault, portal_type=\'Incoming Classification Survey Line\')\n
......@@ -142,8 +142,9 @@ elif resource != 0 :\n
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>vault</string>
<string>resource</string>
<string>price</string>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -70,7 +70,7 @@
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
\n
vault = transaction.getSource()\n
date = transaction.getStartDate()\n
......@@ -153,8 +153,9 @@ elif resource <> 0 :\n
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>vault</string>
<string>date</string>
<string>msg</string>
......
......@@ -65,7 +65,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>transaction = state_change.object\n
<value> <string>transaction = state_change[\'object\']\n
\n
# Check getBaobabSource and getBaobabDestination\n
transaction.Base_checkBaobabSourceAndDestination()\n
......@@ -119,8 +119,9 @@ transaction.Base_checkBaobabSourceAndDestination()\n
<tuple>
<string>state_change</string>
<string>kw</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
</tuple>
</value>
</item>
......
......@@ -69,14 +69,14 @@
from Products.DCWorkflow.DCWorkflow import ValidationFailed\n
from Products.ERP5Type.Message import Message\n
transaction = state_change.object\n
transaction = state_change[\'object\']\n
\n
\n
currency = transaction.getResourceTitle()\n
\n
var_ressource_title = transaction.getResourceTitle().lower()\n
var_ressource_title = var_ressource_title.replace(" ", "_")\n
encaisse_devise = "/encaisse_des_devises/%s/entrante" %(var_ressource_title)\n
encaisse_devise = "/encaisse_des_devises/%s/sortante" %(var_ressource_title)\n
\n
#encaisse_devise = "/encaisse_des_devises/%s/entrante" %(transaction.getResourceTitle().lower())\n
\n
......@@ -172,8 +172,9 @@ if billetage_entre != base_price :\n
<string>ValidationFailed</string>
<string>Products.ERP5Type.Message</string>
<string>Message</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>transaction</string>
<string>_getattr_</string>
<string>currency</string>
<string>var_ressource_title</string>
<string>encaisse_devise</string>
......
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