diff options
| author | Christophe Simonis <chs@odoo.com> | 2018-08-09 15:06:31 +0200 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2018-08-09 15:06:31 +0200 |
| commit | 9cb97a8c2daec720a2ccb8220f07b04a8786876c (patch) | |
| tree | 8875292477a40d9f5d134d743c811231960ce525 /addons/mail/models/mail_template.py | |
| parent | 33e7479865763e8c8255db7e057ef4703bef6093 (diff) | |
| parent | 499af66727e46272efcd7f6785176097642cb096 (diff) | |
[MERGE] forward port branch saas-11.2 up to 499af66727e
Diffstat (limited to 'addons/mail/models/mail_template.py')
| -rw-r--r-- | addons/mail/models/mail_template.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/addons/mail/models/mail_template.py b/addons/mail/models/mail_template.py index 55c0d1beba5..36f7fa3bbb9 100644 --- a/addons/mail/models/mail_template.py +++ b/addons/mail/models/mail_template.py @@ -253,17 +253,17 @@ class MailTemplate(models.Model): def unlink_action(self): for template in self: if template.ref_ir_act_window: - template.ref_ir_act_window.sudo().unlink() + template.ref_ir_act_window.unlink() return True @api.multi def create_action(self): - ActWindowSudo = self.env['ir.actions.act_window'].sudo() + ActWindow = self.env['ir.actions.act_window'] view = self.env.ref('mail.email_compose_message_wizard_form') for template in self: button_name = _('Send Mail (%s)') % template.name - action = ActWindowSudo.create({ + action = ActWindow.create({ 'name': button_name, 'type': 'ir.actions.act_window', 'res_model': 'mail.compose.message', |
