[FIX] sale_crm: fix crm quotation context

Reproduce the issue

    - Install CRM & sale_crm
    - Create an opportunity
    - Create a quotation from the opportunity

    The name of the draft is the opportunity's name instead of "New"

    - Add a "Storage Box" to the quotation, for instance
    - Confirm the quotation
    - Check the delivery note

    The name of the delivery note is the opportunity's name instead of
    WH/OUT/...

Cause

    This issue is caused by 4c9c249c. It seems that we pass an extra
    default_name in the context.

This commit removes the extra default_name from the context.

OPW-2122928

closes odoo/odoo#40943

X-original-commit: e8d91e4a7037d6c05991debb91072de162f0cf56
Signed-off-by: Jason Van Malder <jasonvanmalder@users.noreply.github.com>
This commit is contained in:
jvm-odoo
2019-11-22 08:00:23 +00:00
parent 82df1dfccc
commit 5ff3bec51b
-1
View File
@@ -79,7 +79,6 @@ class CrmLead(models.Model):
'default_campaign_id': self.campaign_id.id,
'default_medium_id': self.medium_id.id,
'default_origin': self.name,
'default_name': self.name,
'default_source_id': self.source_id.id,
'default_company_id': self.company_id.id or self.env.company.id,
}