You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
382 B

  1. # -*- coding: utf-8 -*-
  2. # Copyright 2016 ACSONE SA/NV
  3. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
  4. from odoo import api, models
  5. from ..base_suspend_security import BaseSuspendSecurityUid
  6. class Base(models.AbstractModel):
  7. _inherit = 'base'
  8. @api.model
  9. def suspend_security(self):
  10. return self.sudo(user=BaseSuspendSecurityUid(self.env.uid))