Fix sorting by account in GeneralLegder
For now, sorting on account will sort on the name of the account and not the id. issue3851 review5151002
This commit is contained in:
+4
-2
@@ -1210,10 +1210,12 @@ class GeneralLedger(Report):
|
||||
clause.append(('move.state', '=', 'posted'))
|
||||
lines = MoveLine.search(clause,
|
||||
order=[
|
||||
('account', 'ASC'),
|
||||
('account', 'ASC'), # TODO replace by account.id
|
||||
('date', 'ASC'),
|
||||
])
|
||||
return groupby(lines, operator.attrgetter('account'))
|
||||
key = operator.attrgetter('account')
|
||||
lines.sort(key=key)
|
||||
return groupby(lines, key)
|
||||
|
||||
@classmethod
|
||||
def lines(cls, accounts, periods, posted):
|
||||
|
||||
Reference in New Issue
Block a user