Wrong products moved to the backorder

Registered by EdbO

On this moment, when some products of the same delivery order are not in stock, products which were delivered were moved to the backorder. This is not what a backorder means. It should be on the other way. Products which can't be delivered should be on the backorder. The 'normal' delivery order should get the backorder_id in the database, so you can easily add the backorder to you delivery order.

I've already did some test with the above.

Blueprint information

Status:
Not started
Approver:
None
Priority:
Undefined
Drafter:
None
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Whiteboard

Numerigraphe has an implementation in 5.0, and Kirti Savalia proposed a similar one for 6.1 on 2011-11-21.
They are both flawed in that they break the link between the backorder and the objects that are their origins : procurement orders, sale orders, purchase orders...

A clean fix requieres that either this link is kept intact, or that all the workflows be reworked to take backorders into account (big task).
Numerigraphe has proposed an implementation of the former solution but a unit test was demanded.

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.