[11.0] sale_crm: opportunity sale_count is displayed as quotations count so it should match the number of open quotations (excluding orders)

closes odoo/odoo#29530
This commit is contained in:
Lois Rilo
2018-12-13 19:54:44 +00:00
parent 36551615b7
commit 85b347ea48
+1 -1
View File
@@ -20,7 +20,7 @@ class CrmLead(models.Model):
nbr = 0
company_currency = lead.company_currency or self.env.user.company_id.currency_id
for order in lead.order_ids:
if order.state in ('draft', 'sent', 'sale'):
if order.state in ('draft', 'sent'):
nbr += 1
if order.state not in ('draft', 'sent', 'cancel'):
total += order.currency_id.compute(order.amount_untaxed, company_currency)