[FIX] account: sort partner ledger report by partner ref, name

This commit is contained in:
Denis Ledoux 2014-09-30 15:44:53 +02:00
parent 9b1a9c9518
commit 419c439776
1 changed files with 1 additions and 0 deletions

View File

@ -109,6 +109,7 @@ class third_party_ledger(report_sxw.rml_parse, common_report_header):
"AND account.active ", params)
self.partner_ids = [res['partner_id'] for res in self.cr.dictfetchall()]
objects = obj_partner.browse(self.cr, self.uid, self.partner_ids)
objects.sort(key=lambda x: (x.ref, x.name))
return super(third_party_ledger, self).set_context(objects, data, self.partner_ids, report_type)
def lines(self, partner):