[Erp5-report] r11641 - in /erp5/trunk/bt5/erp5_accounting: SkinTemplateItem/portal_skins/er...
nobody at svn.erp5.org
nobody at svn.erp5.org
Thu Dec 7 18:35:00 CET 2006
Author: jerome
Date: Thu Dec 7 18:34:57 2006
New Revision: 11641
URL: http://svn.erp5.org?rev=11641&view=rev
Log:
update general ledger report to use new columns names in Account_viewAccountingTransactionList/listbox.
Account_statCredit/Account_statDebit reinject selection parameters in the query, because general ledger uses Account_viewAccountingTransactionList with mirror_section_uid or payment_uid.
Modified:
erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getGeneralLedgerReportSectionList.xml
erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statCredit.xml
erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statDebit.xml
erp5/trunk/bt5/erp5_accounting/bt/revision
Modified: erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getGeneralLedgerReportSectionList.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getGeneralLedgerReportSectionList.xml?rev=11641&r1=11640&r2=11641&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getGeneralLedgerReportSectionList.xml (original)
+++ erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getGeneralLedgerReportSectionList.xml Thu Dec 7 18:34:57 2006
@@ -103,16 +103,19 @@
\n
result = []\n
\n
-account_columns = ( (\'date\', \'Date\')\n
- , (\'specific_reference\', \'Reference\')\n
- , (\'title\', \'Label\')\n
- , (\'translated_portal_type\', \'Type\')\n
- , (\'third_party\', \'Third Party\')\n
- , (\'translated_simulation_state_title\', \'State\')\n
- , (\'debit\', \'Debit\')\n
- , (\'credit\', \'Credit\')\n
- , (\'net_balance\', \'Balance\')\n
- )\n
+\n
+account_columns = (\n
+ (\'Movement_getSpecificReference\', \'Reference\'),\n
+ (\'Movement_getExplanationTitle\', \'Title\'),\n
+ (\'date\', \'Date\'),\n
+ (\'Movement_getExplanationTranslatedPortalType\', \'Type\'),\n
+ (\'Movement_getExplanationReference\', \'Invoice Number\'),\n
+ (\'Movement_getMirrorSectionTitle\', \'Third Party\'),\n
+ (\'getTranslatedSimulationStateTitle\', \'State\'),\n
+ (\'Movement_getDebitPrice\', \'Debit\'),\n
+ (\'Movement_getCreditPrice\', \'Credit\'),\n
+ (\'total_price\', \'Balance\'),\n
+ (\'running_total_price\', \'Net\'), )\n
\n
if gap:\n
gap_value_list = [cat_tool.gap.restrictedTraverse(gap)] + \\\n
@@ -133,6 +136,7 @@
del account_inventory_list_cache_params[\'from_date\']\n
\n
for c in gap_value_list:\n
+ # FIXME: this part is not working !\n
account_list = c.getGapRelatedValueList(portal_type="Account")\n
strict_account_list = c.getGapRelatedValueList(portal_type="Account",\n
strict_membership=1)\n
@@ -167,8 +171,8 @@
at_date=at_date,\n
simulation_state=simulation_state):\n
third_party_params = params.copy()\n
- third_party_params[\'mirror_section_uid\'] = third_party_brain.uid\n
third_party_uid = third_party_brain.uid or " = NULL"\n
+ third_party_params[\'mirror_section_uid\'] = third_party_uid\n
title = "%s: %s (%s)" % ( c.getId()\n
, account.getTitle()\n
, third_party_brain.title\n
@@ -186,7 +190,7 @@
selection_params=third_party_params.copy(),\n
selection_columns=account_columns,\n
listbox_display_mode=\'FlatListMode\',\n
- selection_sort_order=[(\'delivery.stop_date\',\n
+ selection_sort_order=[(\'stock.date\',\n
\'ascending\')]))\n
\n
elif account.isMemberOf(\'account_type/asset/cash/bank\'):\n
@@ -196,8 +200,8 @@
simulation_state=simulation_state):\n
bank_params = params.copy()\n
if bank_account_brain.path is not None:\n
- bank_params[\'payment_uid\'] = bank_account_brain.uid\n
bank_account_uid = bank_account_brain.uid or " = NULL"\n
+ bank_params[\'payment_uid\'] = bank_account_uid\n
title = "%s: %s (%s)" % ( c.getId()\n
, account.getTitle()\n
, bank_account_brain.title\n
@@ -218,7 +222,7 @@
selection_params=bank_params.copy(),\n
selection_columns=account_columns,\n
listbox_display_mode=\'FlatListMode\',\n
- selection_sort_order=[(\'delivery.stop_date\',\n
+ selection_sort_order=[(\'stock.date\',\n
\'ascending\')]))\n
elif len(sim_tool.getMovementHistoryList(\n
node_uid=account.getUid(),\n
@@ -232,7 +236,7 @@
selection_params=params,\n
selection_columns=account_columns,\n
listbox_display_mode=\'FlatListMode\',\n
- selection_sort_order=[(\'delivery.stop_date\',\n
+ selection_sort_order=[(\'stock.date\',\n
\'ascending\')]))\n
\n
return result\n
Modified: erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statCredit.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statCredit.xml?rev=11641&r1=11640&r2=11641&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statCredit.xml (original)
+++ erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statCredit.xml Thu Dec 7 18:34:57 2006
@@ -73,6 +73,8 @@
"""\n
kw[\'node_uid\'] = context.getUid()\n
kw[\'omit_input\'] = 1\n
+kw.update(kw[\'selection\'].getParams())\n
+\n
# here, or 0 is to prevent displaying "- 0"\n
return - context.Node_statAccountingBalance(**kw) or 0\n
</string> </value>
@@ -121,6 +123,7 @@
<string>_getattr_</string>
<string>context</string>
<string>_write_</string>
+ <string>_getitem_</string>
<string>_apply_</string>
</tuple>
</value>
Modified: erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statDebit.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statDebit.xml?rev=11641&r1=11640&r2=11641&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statDebit.xml (original)
+++ erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Account_statDebit.xml Thu Dec 7 18:34:57 2006
@@ -73,6 +73,8 @@
"""\n
kw[\'node_uid\'] = context.getUid()\n
kw[\'omit_output\'] = 1\n
+kw.update(kw[\'selection\'].getParams())\n
+\n
return context.Node_statAccountingBalance(**kw)\n
</string> </value>
</item>
@@ -120,6 +122,7 @@
<string>_getattr_</string>
<string>context</string>
<string>_write_</string>
+ <string>_getitem_</string>
<string>_apply_</string>
</tuple>
</value>
Modified: erp5/trunk/bt5/erp5_accounting/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/bt/revision?rev=11641&r1=11640&r2=11641&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/bt/revision (original)
+++ erp5/trunk/bt5/erp5_accounting/bt/revision Thu Dec 7 18:34:57 2006
@@ -1,1 +1,1 @@
-143
+144
More information about the Erp5-report
mailing list