Skip to content
Snippets Groups Projects
Commit 4737e016 authored by Denis Ledoux's avatar Denis Ledoux
Browse files

[FIX] sale: fix _compute_quotations_to_invoice following...

[FIX] sale: fix _compute_quotations_to_invoice following odoo/odoo@9920f20e4c7753bc17bea71dea3a90f7de687196

closes odoo/odoo#35895

Signed-off-by: default avatarDenis Ledoux <beledouxdenis@users.noreply.github.com>
parent 8de430d2
Branches
Tags
No related merge requests found
......@@ -50,9 +50,15 @@ class CrmTeam(models.Model):
""" % where_clause
self.env.cr.execute(select_query, where_clause_args)
quotation_data = self.env.cr.dictfetchall()
teams = self.browse()
for datum in quotation_data:
self.browse(datum['team_id']).quotations_amount = datum['amount_total']
self.browse(datum['team_id']).quotations_count = datum['count']
team = self.browse(datum['team_id'])
team.quotations_amount = datum['amount_total']
team.quotations_count = datum['count']
teams |= team
remaining = (self - teams)
remaining.quotations_amount = 0
remaining.quotations_count = 0
def _compute_sales_to_invoice(self):
sale_order_data = self.env['sale.order'].read_group([
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment