From b8aaff509de6d2a78879fe5d0175f800f79e4543 Mon Sep 17 00:00:00 2001 From: Dibik Date: Fri, 1 Mar 2024 01:54:05 +0530 Subject: [PATCH] Added readonly to fix issue in related field odoo17 --- g2p_registry_membership/models/group_membership.py | 4 ++-- requirements.txt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/g2p_registry_membership/models/group_membership.py b/g2p_registry_membership/models/group_membership.py index 61630d74..9079c3ba 100644 --- a/g2p_registry_membership/models/group_membership.py +++ b/g2p_registry_membership/models/group_membership.py @@ -34,8 +34,8 @@ class G2PGroupMembership(models.Model): store=True, ) is_ended = fields.Boolean(default=False, compute="_compute_is_ended", store=True) - individual_birthdate = fields.Date(related="individual.birthdate") - individual_gender = fields.Selection(related="individual.gender") + individual_birthdate = fields.Date(related="individual.birthdate", readonly=True) + individual_gender = fields.Selection(related="individual.gender", readonly=True) @api.onchange("kind") def _kind_onchange(self): diff --git a/requirements.txt b/requirements.txt index c4d70d07..bc52fc0c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,3 @@ # generated from manifests external_dependencies extendable-pydantic -schwifty \ No newline at end of file +schwifty