forked from Yaltik/golem
Change member.area_id to area_id.root_id
This commit is contained in:
parent
03819f5f3c
commit
71f7299aaf
@ -40,7 +40,7 @@ class GolemMember(models.Model):
|
|||||||
area_ids = self.env['golem.partner.area'].search([])
|
area_ids = self.env['golem.partner.area'].search([])
|
||||||
if member.area_id:
|
if member.area_id:
|
||||||
applicable_areas += area_ids.filtered(
|
applicable_areas += area_ids.filtered(
|
||||||
lambda r: r == member.area_id
|
lambda r: r == member.area_id.root_id
|
||||||
)
|
)
|
||||||
if not applicable_areas and area_ids:
|
if not applicable_areas and area_ids:
|
||||||
applicable_areas += area_ids[0]
|
applicable_areas += area_ids[0]
|
||||||
|
Loading…
Reference in New Issue
Block a user