From 0a553ddf481542f87c48d3bcce1dd900acb8e802 Mon Sep 17 00:00:00 2001 From: Sebastien Robin <seb@nexedi.com> Date: Tue, 16 Jan 2007 09:51:54 +0000 Subject: [PATCH] compute automatically the in and out vault on money deposit rendering git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12107 20353a03-c40f-0410-a6d1-a30d3c3de9de --- ...yDepositRendering_getBaobabDestination.xml | 4 +- .../MoneyDepositRendering_getBaobabSource.xml | 156 ++++++++++++++++++ .../MoneyDepositRendering_view/my_source.xml | 2 +- bt5/erp5_banking_cash/bt/revision | 2 +- 4 files changed, 160 insertions(+), 4 deletions(-) create mode 100644 bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabSource.xml diff --git a/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabDestination.xml b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabDestination.xml index 45ea83f571..bb497c9440 100644 --- a/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabDestination.xml +++ b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabDestination.xml @@ -72,9 +72,9 @@ site = context.Baobab_getVaultSite(source)\n \n if \'devise\' in source:\n - return "%s/caveau/auxiliaire/%s" %(site.getRelativeUrl(), source.split("/")[-2])\n + return "%s/caveau/auxiliaire/encaisse_des_devises/%s" %(site.getRelativeUrl(), source.split("/")[-1])\n else:\n - return "%s/caveau/auxiliaire/%s" %(site.getRelativeUrl(), source.split("/")[-2])\n + return "%s/caveau/auxiliaire/%s" %(site.getRelativeUrl(), source.split("/")[-1])\n </string> </value> </item> <item> diff --git a/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabSource.xml b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabSource.xml new file mode 100644 index 0000000000..f799445a97 --- /dev/null +++ b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_getBaobabSource.xml @@ -0,0 +1,156 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <tuple> + <string>Products.PythonScripts.PythonScript</string> + <string>PythonScript</string> + </tuple> + <none/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_bind_names</string> </key> + <value> + <object> + <klass> + <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>_asgns</string> </key> + <value> + <dictionary> + <item> + <key> <string>name_container</string> </key> + <value> <string>container</string> </value> + </item> + <item> + <key> <string>name_context</string> </key> + <value> <string>context</string> </value> + </item> + <item> + <key> <string>name_m_self</string> </key> + <value> <string>script</string> </value> + </item> + <item> + <key> <string>name_subpath</string> </key> + <value> <string>traverse_subpath</string> </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>_body</string> </key> + <value> <string>source = context.getSource()\n +if source is not None:\n + source = \'%s/%s\' % (source,\'entrante\')\n +return source\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_owner</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>*args, **kw</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>args</string> + <string>kw</string> + <string>_getattr_</string> + <string>context</string> + <string>source</string> + <string>None</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>MoneyDepositRendering_getBaobabSource</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_view/my_source.xml b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_view/my_source.xml index 579dc177f1..68a769d1d0 100644 --- a/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_view/my_source.xml +++ b/bt5/erp5_banking_cash/SkinTemplateItem/portal_skins/erp5_banking_cash/MoneyDepositRendering_view/my_source.xml @@ -281,7 +281,7 @@ <dictionary> <item> <key> <string>_text</string> </key> - <value> <string>python:here.Delivery_getVaultItemList(current_url=here.getSource(), vault_type=(\'site/surface/gros_versement\',), all=1)</string> </value> + <value> <string>python:here.Delivery_getVaultItemList(current_url=here.getSource(), vault_type=(\'site/surface/gros_versement\',))</string> </value> </item> </dictionary> </pickle> diff --git a/bt5/erp5_banking_cash/bt/revision b/bt5/erp5_banking_cash/bt/revision index fa59ff276d..0973804c41 100644 --- a/bt5/erp5_banking_cash/bt/revision +++ b/bt5/erp5_banking_cash/bt/revision @@ -1 +1 @@ -134 \ No newline at end of file +137 \ No newline at end of file -- 2.30.9