[Erp5-report] r10534 - in /erp5/trunk/bt5/erp5_accounting: SkinTemplateItem/portal_skins/er...
nobody at svn.erp5.org
nobody at svn.erp5.org
Wed Oct 4 15:21:23 CEST 2006
Author: jerome
Date: Wed Oct 4 15:21:18 2006
New Revision: 10534
URL: http://svn.erp5.org?rev=10534&view=rev
Log:
if 'hide_grouping' is true, do not show movements having a grouping reference.
In the current configuration, stats shows the total, this is intentional,
because if a movement A (date=2006/12/20) is grouped with a movement B
(date=2007/01/01), the stat should show movement A, even if he is grouped. This
is also a way to see grouping errors.
Modified:
erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml
erp5/trunk/bt5/erp5_accounting/bt/revision
Modified: erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml?rev=10534&r1=10533&r2=10534&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml (original)
+++ erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Node_getAccountingTransactionList.xml Wed Oct 4 15:21:18 2006
@@ -68,7 +68,9 @@
</item>
<item>
<key> <string>_body</string> </key>
- <value> <string>from Products.ERP5Type.Message import Message\n
+ <value> <string encoding="cdata"><![CDATA[
+
+from Products.ERP5Type.Message import Message\n
portal = context.getPortalObject()\n
params = portal.ERP5Accounting_getParams(selection)\n
N_ = lambda msg: Message(\'erp5_ui\', msg)\n
@@ -99,7 +101,7 @@
\n
if from_date:\n
# Create a new parameter list to get the previous balance\n
- get_inventory_kw = params.copy()\n
+ get_inventory_kw = params.copy() # do not include omit_grouping here\n
get_inventory_kw[\'to_date\'] = from_date\n
# TODO: using a list of section_uid \n
# \'where_expression\': " section.portal_type = \'Organisation\' " \n
@@ -141,6 +143,8 @@
getTranslatedSimulationStateTitle=\'\',\n
)\n
new_result = [previous_balance]\n
+ if selection.getParams().get(\'hide_grouping\'):\n
+ params[\'where_expression\'] = \'catalog.grouping_reference is NULL\'\n
new_result.extend(\n
portal.portal_simulation.getMovementHistoryList(\n
from_date=from_date,\n
@@ -162,8 +166,10 @@
sort_on=sort_on,\n
src__=1,\n
**params))\n
- \n
-# We try not to convert to a list.\n
+\n
+if selection.getParams().get(\'hide_grouping\'):\n
+ params[\'where_expression\'] = \'catalog.grouping_reference is NULL\'\n
+# We try not to convert to a list, hence the copy & paste\n
return portal.portal_simulation.getMovementHistoryList(\n
from_date=from_date,\n
initial_running_total_price=net_balance,\n
@@ -172,7 +178,9 @@
selection_domain_join_column=\'section_uid\',\n
sort_on=sort_on,\n
**params)\n
-</string> </value>
+
+
+]]></string> </value>
</item>
<item>
<key> <string>_code</string> </key>
Modified: erp5/trunk/bt5/erp5_accounting/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/bt/revision?rev=10534&r1=10533&r2=10534&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/bt/revision (original)
+++ erp5/trunk/bt5/erp5_accounting/bt/revision Wed Oct 4 15:21:18 2006
@@ -1,1 +1,1 @@
-58
+59
More information about the Erp5-report
mailing list