c389a67d35fd3529693ca0b436a7b63925206d1e
user_has_group work in a frontend context
Without this, `user_has_group` does not work in a frontend context. The frontend session info seems to have been introduced with minimal requirements with [1]. It was later populated with more keys, each time when facing a special need. See [2]. Somehow, the `uid` need was never faced, thus never added, thus `user_has_group` never worked in the frontend, apparently. The fact that this method is not working in a frontend context is something that comes back from time to time without really going further. The chance is here taken to fix that once and for all. Note that we don't want to add the `uid` key in the session frontend context as that would not be stable friendly, some users might now relate to that attribute not being set in the frontend context. This fix is then patching that method to work everywhere. [1]: https://github.com/odoo/odoo/commit/0980546f4115ff7d072371d1b57d30000d07ce2c [2]: https://github.com/odoo/odoo/blame/da8d418ff08aa55c7378887c9a5a06a5d12b72c0/addons/website/views/website_templates.xml#L128 closes odoo/odoo#89890 X-original-commit: 9aafec4ed94b9f7f2af42970dd14142ee5ca70dc Signed-off-by: Romain Derie (rde) <rde@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, ...
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.
To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%