[FIX] partner_profiles: correct unlink() for position profiles
This commit is contained in:
committed by
Stéphan Sainléger
parent
eba51e1654
commit
a5993e3786
@@ -3,7 +3,7 @@
|
||||
|
||||
{
|
||||
"name": "partner_profiles",
|
||||
"version": "12.0.2.5.0",
|
||||
"version": "12.0.2.5.1",
|
||||
"author": "Elabore",
|
||||
"website": "https://elabore.coop",
|
||||
"maintainer": "Stéphan Sainléger",
|
||||
|
@@ -140,7 +140,7 @@ class res_partner(models.Model):
|
||||
for partner in self:
|
||||
if partner.is_company:
|
||||
# Delete position profiles linked to the company main profile
|
||||
for position in self.structure_position_ids:
|
||||
for position in partner.structure_position_ids:
|
||||
position.unlink()
|
||||
return super(res_partner, self).unlink()
|
||||
|
||||
|
Reference in New Issue
Block a user