[Erp5-report] r13604 - in /erp5/trunk/bt5/erp5_accounting: SkinTemplateItem/portal_skins/er...

nobody at svn.erp5.org nobody at svn.erp5.org
Fri Mar 23 19:07:26 CET 2007


Author: jerome
Date: Fri Mar 23 19:07:24 2007
New Revision: 13604

URL: http://svn.erp5.org?rev=13604&view=rev
Log:
When calculating the remaining price, only consider payable / receivable
accounts that are used on this invoice (ie. if another account is used in a
related tansaction, ignore this amount).


Modified:
    erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Invoice_getRemainingTotalPayablePrice.xml
    erp5/trunk/bt5/erp5_accounting/bt/revision

Modified: erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Invoice_getRemainingTotalPayablePrice.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Invoice_getRemainingTotalPayablePrice.xml?rev=13604&r1=13603&r2=13604&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Invoice_getRemainingTotalPayablePrice.xml (original)
+++ erp5/trunk/bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/Invoice_getRemainingTotalPayablePrice.xml Fri Mar 23 19:07:24 2007
@@ -131,8 +131,8 @@
   # if we have a payment related to multiple invoices, we cannot say the\n
   # remaining price on those invoices.\n
   for other_invoice in [ tr for tr in related_transaction.getCausalityValueList(\n
-                         portal_type=context.getPortalAccountingTransactionTypeList())\n
-                         if tr != context ]:\n
+             portal_type=context.getPortalAccountingTransactionTypeList())\n
+             if tr != context ]:\n
     other_invoice_is_source = \\\n
                     other_invoice.AccountingTransaction_isSourceView()\n
     for other_line in other_invoice.getMovementList(\n
@@ -168,8 +168,9 @@
     \n
     if node_value is not None and \\\n
         node_value.getAccountTypeId() in (\'payable\', \'receivable\'):\n
-      key = (node_value.getRelativeUrl(), mirror_section)\n
-      total_payable_price_per_node_section[key] =\\\n
+      if node_value in accounts_in_context:\n
+        key = (node_value.getRelativeUrl(), mirror_section)\n
+        total_payable_price_per_node_section[key] =\\\n
             total_payable_price_per_node_section.get(key, 0) + amount\n
 \n
 if detailed:\n

Modified: erp5/trunk/bt5/erp5_accounting/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_accounting/bt/revision?rev=13604&r1=13603&r2=13604&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_accounting/bt/revision (original)
+++ erp5/trunk/bt5/erp5_accounting/bt/revision Fri Mar 23 19:07:24 2007
@@ -1,1 +1,1 @@
-224
+225




More information about the Erp5-report mailing list