Trial balance - wrong account sort

Bug #1166857 reported by Cedric Le Brouster(OpenFire)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Camptocamp Financial Addons
New
Undecided
Unassigned

Bug Description

Hello,

I had bad sorted accounts on the trial balance.
The problem is the use of python method used to remove doubles : list(set(accounts))
This doest not preserve the order of the list

I just corrected it like this for now and it works fine (but no more doubles removing I guess) :

=== modified file 'addons/account_financial_report_webkit/report/common_reports.py'
--- addons/account_financial_report_webkit/report/common_reports.py 2012-08-14 15:29:16 +0000
+++ addons/account_financial_report_webkit/report/common_reports.py 2013-04-09 14:52:34 +0000
@@ -176,7 +176,8 @@
         for account_id in account_ids:
             accounts.append(account_id)
             accounts += acc_obj._get_children_and_consol(self.cursor, self.uid, account_id, context=context)
- res_ids = list(set(accounts))
+ #res_ids = list(set(accounts))
+ res_ids = accounts
         res_ids = self.sort_accounts_with_structure(account_ids, res_ids, context=context)

         if exclude_type or only_type or filter_report_type:

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.