Andrea Grazioso (agr-odoo) 048d7e8718 [FIX] point_of_sale: force company of pos order in controller
Have company 1 (main company) and company 2
Activate Website for company 1
Switch to company 2
Setup a POS
In Settings > Point of Sale, activate 'Use QR code on ticket'
Open POS session
Make an order, save qr link from receipt, close session
Open the saved link without being logged in
Complete form and request invoice

Issue:
Error will block the operation
```
Incompatible companies on records:
- '/ (Reversal of POS closing entry POSS/2024/01/0004 for order Shop/0004 from session POS/00002) 16%' belongs to company False and 'Account' (account_id: '209.01.01 VAT carried forward not collected') belongs to another company.
- '/ (Reversal of POS closing entry POSS/2024/01/0004 for order Shop/0004 from session POS/00002) 16%' belongs to company False and 'Originator Tax Distribution Line' (tax_repartition_line_id: 'account.tax.repartition.line,54') belongs to another company.
- '/ (Reversal of POS closing entry POSS/2024/01/0004 for order Shop/0004 from session POS/00002) Acoustic Bloc Screens' belongs to company False and 'Account' (account_id: '401.01.01 Sales and/or services taxed at the general rate') belongs to another company.
- '/ (Reversal of POS closing entry POSS/2024/01/0004 for order Shop/0004 from session POS/00002) Acoustic Bloc Screens' belongs to company False and 'Taxes' (tax_ids: '16% (MX)') belongs to another company.
- '/ (Reversal of POS closing entry POSS/2024/01/0004 for order Shop/0004 from session POS/00002) 105.01.02 105.01.02' belongs to company False and 'Account' (account_id: '105.01.02 National customers (PoS)') belongs to another company.
```
This occurs because when Website is installed, requests from public user
will keep in context the id of the company associated to the website,
company 1 in this case.

opw-3629683

closes odoo/odoo#149410

X-original-commit: 6fce2e5bf34468099a0c62669687847ed36621bf
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Andrea Grazioso (agr) <agr@odoo.com>
2024-01-16 09:55:27 +00:00
…
…
…
…
…
…

Build Status Tech Doc Help Nightly Builds

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

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%