Depends on the invoice and the content of the invoice.
If you need to adjust the invoice, the full sale should be credited.
Otherwise you can just return the goods from the customer and then re-send them with the correct lot. The drawback is that such shipment won’t be linked to the original sale (unless you set the proper origins).
I’m wondering if we should not allow to edit lot on stock move done as long as there is no closed period.
Otherwise I see no other solution than doing a return and then a shipment with correct values.
We could probably have some wizard to help create such return/shipments.
In our case, we need to attach the invoice to the shipment (international shipping), so we do the shipment to create the invoice and then we could send the shipment… (we should need an extra state ‘send’ after the ‘done’ state of the shipment out )
It would be very complex… assignation is already complicated… it is more than just updating some fields… what about if you switch a location for another… which lots are available ? is it the same product ? is there enough quantity ?
Not necessary. When mistakes happen, data relation can be messy.
What may be tricky is for the “Shipping Invoice” document because the value on the right shipment may be not correct if done manually (the unit price may not be the one on the sale for example).
I see no point to manage errors with such machinery way. This is just over engineering.
We are also asked frequently for a valued delivery note, so we usually add some @property and make use of TaxableMixin to display the sale amounts in a like a value delivery note.
What about creating this document on core?