[FIX] account: aged partner balance report consistent return
Before this commit, the function that computes the aged partner balance could return a list instead of a dict if no partner were found After this commit, we make the function's signature consistent closes #26095
This commit is contained in:
@@ -68,7 +68,7 @@ class ReportAgedPartnerBalance(models.AbstractModel):
|
|||||||
partner_ids = [partner['partner_id'] for partner in partners if partner['partner_id']]
|
partner_ids = [partner['partner_id'] for partner in partners if partner['partner_id']]
|
||||||
lines = dict((partner['partner_id'] or False, []) for partner in partners)
|
lines = dict((partner['partner_id'] or False, []) for partner in partners)
|
||||||
if not partner_ids:
|
if not partner_ids:
|
||||||
return [], [], []
|
return [], [], {}
|
||||||
|
|
||||||
# This dictionary will store the not due amount of all partners
|
# This dictionary will store the not due amount of all partners
|
||||||
undue_amounts = {}
|
undue_amounts = {}
|
||||||
|
|||||||
Reference in New Issue
Block a user