eafabb58c39ec356d20be6ae0ec6038a650240b1
Steps to reproduce the bug: - Install [l10n_it_ddt] - Create a storable product “P1” - Create a SO for “P1” with qty 3 - Deliver 1 unit and create a backorder - Generate the invoice for the delivered qty: 1 - Post the invoice - smart button with the link to DDT n°1 appears - Deliver the remaining 2 units - Create the second invoice - Post the invoice Problem: The link to DDT appears but with the 2 pickings, whereas in this case only the 2nd picking is linked to the invoice. Before using the `account.move.line` records, we sorted them by date in order to always use the first created one to link it with the first picking created, however if two `account.move.line` were created in the same days, they will be ordered randomly, so we also have to sort them by id if the date is the same. opw-2968401 closes odoo/odoo#100998 X-original-commit: e8e99c05696308422183516e68c0b9ed5495d7ca Signed-off-by: Josse Colpaert <jco@odoo.com> Signed-off-by: Djamel Touati (otd) <otd@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%