[FIX] base: Individual contact gets Company icon
Steps to reproduce: - Create a contact (Company). - Create a "child" in this company. - Select "Contact" as type of address. - Create an individual child of the company. Bug: instead of having the Individual icon (Human being), it gets the Company icon (Building). Fix: the behavior must be the same as in 8.0, the avatar must be used for a contact which is not a company. opw:683105
This commit is contained in:
@@ -245,7 +245,7 @@ class Partner(models.Model, FormatAddress):
|
||||
|
||||
colorize, img_path, image = False, False, False
|
||||
|
||||
if partner_type in ['contact', 'other'] and parent_id:
|
||||
if partner_type in ['other'] and parent_id:
|
||||
parent_image = self.browse(parent_id).image
|
||||
image = parent_image and parent_image.decode('base64') or None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user