Keep the origin of customer shipments when sync inventory to outgoing moves
Current _sync_inventory_to_outgoing() method when synchronize products not keep the origin from outgoing moves
When create a shipment from a sale (or grouped sale shipments) with same product, and change the qty in inventory moves, when pack the sync_inventory_to_outgoing update the qty from the key "product" and not keep the origin.
Finally, when create invoice lines from sale (done the shipment), will be create invoice lines that have not been actually sent because "sync inventory to outgoing moves" not keep the origin.
Example:
Outgoing moves:
>>> for move in shipment.outgoing_moves: move.id, move.product.id, move.quantity, move.origin, move.state
...
(49511, 160, 100.0, Pool().get('sale.line')(13911), 'done')→ ok. Incoming moves qty: 100
(49510, 1717, 25.0, Pool().get('sale.line')(13914), 'done') → ok. Incoming moves qty: 25
(49517, 459, 50.0, Pool().get('sale.line')(13915), 'done')→ ko. The incoming move was removed.
(49508, 459, 0.0, Pool().get('sale.line')(13912), 'done') → ko: incoming moves qty: 50
(49509, 3466, 0.0, Pool().get('sale.line')(13913), 'done') → ko: incoming moves qty: 50
(49518, 3466, 50.0, Pool().get('sale.line')(13916), 'done')→ ko. The incoming move was removed.
Inventory moves:
>>> for move in shipment.inventory_moves: move.id, move.product.id, move.quantity, move.origin, move.state
...
(390665, 160, 100.0, Pool().get('stock.move')(49511), 'done')
(390669, 1717, 25.0, Pool().get('stock.move')(49510), 'done')
(390666, 459, 50.0, Pool().get('stock.move')(49508), 'done')
(390670, 3466, 50.0, Pool().get('stock.move')(49509), 'done')