mirror of
https://github.com/OCA/account-financial-tools.git
synced 2025-02-02 12:47:26 +02:00
account_asset_management: fix group_assets sorting
This commit is contained in:
committed by
Stefan Rijnhart
parent
347aa73af8
commit
0f7a66282d
@@ -441,7 +441,8 @@ class AssetReportXlsx(models.AbstractModel):
|
||||
else:
|
||||
group_assets = assets
|
||||
group_assets = group_assets.sorted(
|
||||
lambda r: (r.date_start or '', r.code))
|
||||
lambda r: (r.date_start or "", r.code or "", r.name)
|
||||
)
|
||||
grouped_assets[group] = {'assets': group_assets}
|
||||
for child in group.child_ids:
|
||||
self._group_assets(assets, child, grouped_assets[group])
|
||||
|
||||
Reference in New Issue
Block a user