Files
odoo_source/addons/web/controllers
Yolann Sabaux dc8cf87fc8 [FIX] web: fetch right company_id
Steps to reproduce:
- Have two companies set up
- In settings, check for company 2 the Files Centralization
- For a Product, upload a document

Issue:
The document will not appear in Documents.
It will only appear if the option is checked for company 1

Cause:
The company_id is not fetched correctly throughout the process.
There is a similar solution for the specific `documents` upload route:
https://github.com/odoo/enterprise/blob/bdf712d66c3e5cee70a6b424b69a618fe655a39f/documents/controllers/main.py#L147-L149

Solution:
Get the id directly from the cookies

opw-2774365

closes odoo/odoo#91751

X-original-commit: 46db92d5211c215d07448676e619154390b7147f
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: yosa-odoo <yosa@odoo.com>
2022-05-19 13:45:05 +02:00
..
2022-05-19 13:45:05 +02:00
…
2022-03-09 10:23:56 +00:00