diff options
| author | Christophe Simonis <chs@odoo.com> | 2018-08-07 19:08:07 +0200 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2018-08-07 19:08:07 +0200 |
| commit | efe2dcd7ae6573bf6830918d58f5b89739d67301 (patch) | |
| tree | aec1110b92af4cd8b9153d8b08d63c6878c3efe2 /addons/mail/models/mail_template.py | |
| parent | d7e2c767ce51ddf112babc5507105da4dc127279 (diff) | |
| parent | ced9156a97ea502050b4e827ef2237fa2cd9410f (diff) | |
[MERGE] forward port branch 11.0 up to ced9156a97e
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 cb9c4a433a8..281a70d649e 100644 --- a/addons/mail/models/mail_template.py +++ b/addons/mail/models/mail_template.py @@ -283,17 +283,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', |
