From 71f7299aaf6b9601bf6986b42b6f0bdc9739f702 Mon Sep 17 00:00:00 2001 From: youssef Date: Fri, 12 Oct 2018 16:05:01 +0100 Subject: [PATCH] Change member.area_id to area_id.root_id --- golem_activity_registration_custom_price/models/golem_member.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/golem_activity_registration_custom_price/models/golem_member.py b/golem_activity_registration_custom_price/models/golem_member.py index 1ce0130..ebac655 100644 --- a/golem_activity_registration_custom_price/models/golem_member.py +++ b/golem_activity_registration_custom_price/models/golem_member.py @@ -40,7 +40,7 @@ class GolemMember(models.Model): area_ids = self.env['golem.partner.area'].search([]) if member.area_id: 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: applicable_areas += area_ids[0]