Nicolas Lempereur 49913f1f35 [FIX] pos_sale: decrease sale.report ID conflict
issues:

- search sale.report with `('order_id', '!=', False)` in list view =>
  you might get lines without sale order, with the wrong product, ...

- group sale.report by product on list view => you might get lines with
  a different product than the group

cause:

the sale.report IDs are an union of sale_order_line.id and
pos_order_line.id => so there can be 2 lines of sale.report with same
IDs but pointing two completely different record.

rejected solution:

using row_number() over() for ID after the UNION ALL => rejected since
there was a `row_number` on sale.report at one point that was removed
because of performance issue (03bd6f5243e189cd05b3fc7ad774cc07ea733e14).

solution:

using negative IDs for pos_order_line lines

drawback:

in 14.0, we already use negative IDs for sale_order without lines =>
the probability of conflict is lower for this case and sale.order.line
not being in conflict is better.

opw-2586062
opw-2694529

closes odoo/odoo#83621

X-original-commit: cdaf046637704b53047b79984669ed2044cd8da6
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2022-03-16 13:16:17 +01:00
…
…
…
2021-10-07 17:59:53 +00:00
2022-01-14 15:44:52 +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%