From 8a9270dcbe9e23a198c2fd69669797143c51ed11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com> Date: Thu, 22 Mar 2007 15:51:27 +0000 Subject: [PATCH] Pass both selection and selection_name to ERP5Accounting_getParams; the script will decide which one to use (depending on which version of Products code you have, either selection or selection_name should be None). git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13571 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../erp5_accounting/AccountModule_getAccountList.xml | 3 ++- .../AccountModule_getAccountingTransactionCount.xml | 3 ++- .../portal_skins/erp5_accounting/AccountModule_getBalance.xml | 3 ++- .../portal_skins/erp5_accounting/AccountModule_statBalance.xml | 3 ++- .../erp5_accounting/Node_getAccountingTransactionList.xml | 3 ++- .../erp5_accounting/Node_statAccountingBalance.xml | 3 ++- bt5/erp5_accounting/bt/revision | 2 +- 7 files changed, 13 insertions(+), 7 deletions(-) diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountList.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountList.xml index 3d421510c8..43e9f39040 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountList.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountList.xml @@ -83,7 +83,8 @@ if not id:\n kwd[\'select_expression\'] = "\'%s\' AS accounting_transaction_line_currency" % id\n \n # precision for editable fields\n -params = context.ERP5Accounting_getParams(selection_name)\n +params = context.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n if params.get(\'precision\', None) is not None:\n context.REQUEST.set(\'precision\', params[\'precision\'])\n \n diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountingTransactionCount.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountingTransactionCount.xml index e332ba8189..6e1f823714 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountingTransactionCount.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getAccountingTransactionCount.xml @@ -68,7 +68,8 @@ </item> <item> <key> <string>_body</string> </key> - <value> <string>kwd = context.ERP5Accounting_getParams(selection_name)\n + <value> <string>kwd = context.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n \n # XXX missing :(\n # this may fail if we have movements on something else than accounts\n diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getBalance.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getBalance.xml index c5c161017f..9e16784f93 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getBalance.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getBalance.xml @@ -69,7 +69,8 @@ <item> <key> <string>_body</string> </key> <value> <string>portal = context.getPortalObject()\n -params = portal.ERP5Accounting_getParams(selection_name)\n +params = portal.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n params[\'omit_input\'] = omit_input\n params[\'omit_output\'] = omit_output\n \n diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_statBalance.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_statBalance.xml index 1e68416c8f..801e004cff 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_statBalance.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_statBalance.xml @@ -69,7 +69,8 @@ <item> <key> <string>_body</string> </key> <value> <string>portal = context.getPortalObject()\n -params = portal.ERP5Accounting_getParams(selection_name)\n +params = portal.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n selection_params = context.portal_selections.getSelectionParamsFor(selection_name)\n \n params[\'omit_input\'] = omit_input\n diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml index d35094eef5..52ff928cc0 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml @@ -72,7 +72,8 @@ from Products.ERP5Type.Message import Message\n portal = context.getPortalObject()\n -params = portal.ERP5Accounting_getParams(selection_name)\n +params = portal.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n N_ = lambda msg: Message(\'erp5_ui\', msg)\n \n if params.get(\'precision\', None) is not None:\n diff --git a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_statAccountingBalance.xml b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_statAccountingBalance.xml index f212545eb7..8a412de930 100644 --- a/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_statAccountingBalance.xml +++ b/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_statAccountingBalance.xml @@ -69,7 +69,8 @@ <item> <key> <string>_body</string> </key> <value> <string>portal = context.getPortalObject()\n -params = portal.ERP5Accounting_getParams(selection_name)\n +params = portal.ERP5Accounting_getParams(selection_name=selection_name,\n + selection=selection)\n \n if kw.get(\'node_uid\'):\n params[\'node_uid\'] = kw[\'node_uid\']\n diff --git a/bt5/erp5_accounting/bt/revision b/bt5/erp5_accounting/bt/revision index cc4f7f3feb..1199cd493e 100644 --- a/bt5/erp5_accounting/bt/revision +++ b/bt5/erp5_accounting/bt/revision @@ -1 +1 @@ -218 \ No newline at end of file +219 \ No newline at end of file -- 2.30.9