Skip to content
Snippets Groups Projects
Commit 621454fa authored by Nicolas Lempereur's avatar Nicolas Lempereur
Browse files

[FIX] sale_management: quotation template+sequence=lessbug


Scenario:

- set a quotation template on a quotation that adds lines ordered with
  a sequence (eg. 3 lines with sequences 10, 11, 12)
- add lines in this quotation
- save

Issue:

The added lines have sequence 10 and the seen order changes.

This is caused by 6f11060d that tries to
mitigate a more rare issue when there is more than one page of lines.

Solution:

Reverting the previous fix, and setting the sequence of the first line
to -99:

- when resequencing the first page, the sequence will be -99 to -60 =>
  records from the second page will not get in the first page

- new lines will be added at the end

Issues still present:

- when resequencing the second page, item from 3 pages get into it (it
  was already the case before 6f11060d)

- when adding a new line (without resequencing), it is added at the end
  and not at the beginning of the next page

But those are just behavior in any list view (as is the original issue
of 6f11060d, but since it was partially
fixed for a year, this patch try to give an in-between solution instead
of just reverting it).

opw-2833913

closes odoo/odoo#119890

X-original-commit: e342f3dd3d9454cae50515b9f75603579051daca
Signed-off-by: default avatarNicolas Lempereur (nle) <nle@odoo.com>
parent 034b317a
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment