Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] website_form: fix wrong user sending website forms
Issue - Set outgoing mail server - Install Online Ticket Submission - Publish an Helpdesk Team - Log out - Create a ticket from the helpdesk form The user who created the ticket is "Public User" He has no email address, so the mail is not sent Cause insert_record method in website_form/main.py uses .sudo() In v12 => sudo replaces the user in env by the superuser => ok In v13 => sudo adds a flag "su" and does not replace the user in env Solution Add a with_user(SUPERUSER_ID) to the create method's call in insert_record OPW-2196668 closes odoo#45944 Signed-off-by: Nicolas Martinelli (nim) <[email protected]>
- Loading branch information