From 61b0800e69ccb5b0e0326781ed47980dddc2b2a5 Mon Sep 17 00:00:00 2001 From: Wolfgang Pichler Date: Tue, 23 Aug 2022 10:28:36 +0200 Subject: [PATCH] [FIX] Fixed normal user access error on _selection_related_model_instance to ir.model, sudo is required here --- mail_activity_board/models/mail_activity.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mail_activity_board/models/mail_activity.py b/mail_activity_board/models/mail_activity.py index 1862f67..f05a5c4 100644 --- a/mail_activity_board/models/mail_activity.py +++ b/mail_activity_board/models/mail_activity.py @@ -33,7 +33,7 @@ class MailActivity(models.Model): @api.model def _selection_related_model_instance(self): - models = self.env["ir.model"].search([("is_mail_activity", "=", True)]) + models = self.env["ir.model"].sudo().search([("is_mail_activity", "=", True)]) return [(model.model, model.name) for model in models] def open_origin(self):