diff --git a/event_type_description/models/event_event.py b/event_type_description/models/event_event.py index d4b445f..52cf5b0 100644 --- a/event_type_description/models/event_event.py +++ b/event_type_description/models/event_event.py @@ -12,21 +12,20 @@ class EventEvent(models.Model): readonly=False, # default="", ) - can_push = fields.Boolean( - "Can push description", - compute="_get_can_push", - ) can_pull = fields.Boolean( "Can pull description", compute="_get_can_pull", + store=True, + ) + can_push = fields.Boolean( + "Can push description", + compute="_get_can_push", ) @api.depends("event_type_id") def _compute_description(self): for event in self: - if event.event_type_id and not is_html_empty( - event.event_type_id.description - ): + if event.can_pull: event.description = event.event_type_id.description # Pull from template