691dc424a1d04c7ea4fb87663b17922efd5bcaf5
- Activate multi-company
- Create a company B
- Switch to company B
- Create an allocation request
An access error is raised.
Commit 7f775f0677 added a `sudo` call in order to prevent an access
error. However, it implies that the fallback value `self.env.user`
refers to the SUPERUSER, not the current user anymore. If the current
user is not in the same company than the SUPERUSER, the multi-company
record rules will be triggered.
The fallback is changed to an empty recordset, and selecting the current
user is done out of the method called with `sudo`.
opw-2003137
closes odoo/odoo#33804
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
…
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, Purchase Management, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
Then follow the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%