From a0ae236a2092fda793d8de2848770b7f403c65fc Mon Sep 17 00:00:00 2001 From: MAHAMADASIF ANSARI Date: Fri, 20 May 2022 10:05:18 +0000 Subject: [PATCH] [IMP] sale_crm: remove default 'Customer' filter When going to quotations from a lead by clicking on a stat button, the result we see can sometimes be inconsistent with the count of a stat button (count can be higher than the quotation we see). This happens because we set a default filter which shows quotations only for the contact set on the current lead. However, even if the contact's company is set on another quotations, we should see them since they are considered for the stat button data. This commit removes the default 'Customer' filter and thus allowing also to see the quotation linked to customer's company. This does not have any side effect because the default domain makes sure that quotations we see are linked with current opportunity only. task-2859354 closes odoo/odoo#91898 Signed-off-by: Thibault Delavallee (tde) --- addons/sale_crm/models/crm_lead.py | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/sale_crm/models/crm_lead.py b/addons/sale_crm/models/crm_lead.py index 30aa1ce55bf..91f1b00a7b1 100644 --- a/addons/sale_crm/models/crm_lead.py +++ b/addons/sale_crm/models/crm_lead.py @@ -73,7 +73,6 @@ class CrmLead(models.Model): """ Prepares the context for a new quotation (sale.order) by sharing the values of common fields """ self.ensure_one() quotation_context = { - 'search_default_partner_id': self.partner_id.id, 'default_opportunity_id': self.id, 'default_partner_id': self.partner_id.id, 'default_campaign_id': self.campaign_id.id,