-
-
Notifications
You must be signed in to change notification settings - Fork 389
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[8.0][crm_lead_firstname] Link crm and partner_firstname modules. #75
Conversation
Travis fails, runbot fails, I cannot test it. |
It should work now. |
This module adds the lastname field to leads and converts current contact name into contact firstname. Allows to transfer that from and to res.partner objects.
Without respecting the order, the user could get to a situation where you are updating a field without lastname to set `firstname=False, lastname="something"` and fail because Odoo started by `firstname` and that lead to a temporary situation where no names are set and `EmptyNamesError` gets raised. With this patch, you force Odoo to write first the field with value, whith avoids that situation and always works.
I rebased to make runbot rebuild, let's see if today it works. |
Runbot says:
|
I tested functionality and it's OK! Thanks 👍 |
#75 (comment) fixed in OCA/partner-contact#250 |
if not is_company and partner_id: | ||
partner = self.env["res.partner"].browse(partner_id) | ||
partner.update( | ||
OrderedDict( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do you use this strange construction?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See 2ae3a2c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should write the same commit text as comment for clarifying it to the next code reader
All fixed. |
👍 |
1 similar comment
👍 |
[8.0][crm_lead_firstname] Link crm and partner_firstname modules.
This module adds the lastname field to leads and converts current contact name into contact firstname.
Allows to transfer that from and to res.partner objects.
@rafaelbn