[FIX] account: Field total_invoiced in res.partner doesn't include archived children
This commit is contained in:
committed by
Christophe Matthieu
parent
d329b946d6
commit
40d4cdd39f
@@ -296,7 +296,7 @@ class ResPartner(models.Model):
|
|||||||
all_partner_ids = []
|
all_partner_ids = []
|
||||||
for partner in self:
|
for partner in self:
|
||||||
# price_total is in the company currency
|
# price_total is in the company currency
|
||||||
all_partners_and_children[partner] = self.search([('id', 'child_of', partner.id)]).ids
|
all_partners_and_children[partner] = self.with_context(active_test=False).search([('id', 'child_of', partner.id)]).ids
|
||||||
all_partner_ids += all_partners_and_children[partner]
|
all_partner_ids += all_partners_and_children[partner]
|
||||||
|
|
||||||
# searching account.invoice.report via the orm is comparatively expensive
|
# searching account.invoice.report via the orm is comparatively expensive
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
Spain, 2015-05-28
|
||||||
|
|
||||||
|
I hereby agree to the terms of the Odoo Individual Contributor License Agreement v1.0.
|
||||||
|
|
||||||
|
I declare that I am authorized and able to make this agreement and sign this declaration.
|
||||||
|
|
||||||
|
Signed,
|
||||||
|
|
||||||
|
Carlos Dauden carlos.dauden@tecnativa.com https://github.com/carlosdauden
|
||||||
Reference in New Issue
Block a user