odoo/odoo#188333

Created by Bugfix, Maruan Aguerdouh Mohtar (magm)
Merged at 602c5a29842017cddd31b07d25abb7e6449c8bde

Statuses:

label
odoo-dev:saas-17.2-opw-4240873-preserve_slides_sequence_when_duplicating-magm
head
1ae1cdd2159fffe546e7ef2efc6a0d54fa72e776
merged
8 months ago by SM Learn, Florian Charlier (flch)
odoo/odoo
saas-17.2 #188333
saas-17.4 #194049
18.0 #194055
saas-18.1 #194056
saas-18.2
saas-18.3
saas-18.4
19.0
master #194081

[FIX] website_slides: preserve order of slides when duplicating

Steps to reproduce:

  1. In elearning get a current course or create a new one.
  2. Add or just reorder some of the slides/sections.
  3. Duplicate the course.

After the changes applied to improve the batch call of copy in 4ac2702c31f0e95f33f9ad554e7350bef9dab8bd the values that we get after the copy are ordered by id instead of preserving the original order, so for this case we can make sure to reorder the values and mantain the proper sequence when duplicating inside copy_data().

opw-4240873