Hi
I'm trying to send an email after saving a custom model, but, if I'm not "Administrator"
I get this error
File "/mnt/extra-addons/odoo-teamservice/addons/teamservice/mailform/models/mailer.py", line 91, in _send_email mails = mail_mail_obj.create(values)
File "/opt/odoo/sources/addons/fetchmail/models/mail_mail.py", line 18, in create return super(MailMail, self).create(values)
File "/opt/odoo/sources/addons/mail/models/mail_mail.py", line 65, in create return super(MailMail, self).create(values)
File "/opt/odoo/sources/odoo/models.py", line 3811, in create record = self.browse(self._create(old_vals)) File "/opt/odoo/sources/odoo/models.py", line 3867, in _create parent_id = self.env[parent_model].create(parent_vals).id
File "/opt/odoo/sources/addons/mail/models/mail_message.py", line 726, in create message = super(Message, self).create(values)
File "/opt/odoo/sources/odoo/models.py", line 3811, in create record = self.browse(self._create(old_vals))
File "/opt/odoo/sources/odoo/models.py", line 3975, in _create self.check_access_rule('create')
File "/opt/odoo/sources/addons/website_mail/models/mail_message.py", line 58, in check_access_rule return super(MailMessage, self).check_access_rule(operation=operation)
File "/opt/odoo/sources/addons/mail/models/mail_message.py", line 670, in check_access_rule (self._description, operation))
AccessError: (u'The requested operation cannot be completed due to security restrictions. Please contact your system administrator.\n\n(Document type: Message, Operation: create)', None)
In my model I set also
_inherit = 'mail.thread'
Could anyone help me please?
Thank you
Pietro Conconi.