summaryrefslogtreecommitdiff
path: root/addons/web_unsplash/models/res_users.py
diff options
context:
space:
mode:
Diffstat (limited to 'addons/web_unsplash/models/res_users.py')
-rw-r--r--addons/web_unsplash/models/res_users.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/addons/web_unsplash/models/res_users.py b/addons/web_unsplash/models/res_users.py
new file mode 100644
index 00000000..375a0ce3
--- /dev/null
+++ b/addons/web_unsplash/models/res_users.py
@@ -0,0 +1,11 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+from odoo import api, models
+
+
+class ResUsers(models.Model):
+ _inherit = 'res.users'
+
+ def _has_unsplash_key_rights(self):
+ self.ensure_one()
+ return self.has_group('base.group_erp_manager')