Ir al contenido
Menú
Se marcó esta pregunta

Why does Odoo consolidate into a single transaction at the destination the transfers it receives from the same origin?

when using a route and rule with a transit location to validate the receipt at the destination, Odoo, upon processing the first transfer for 1 box, creates a transfer WH/INT/000001 at the destination for 1 box of the product. If that transfer is not processed at the destination and I perform a new operation at the origin with the same destination, then Odoo incorporates the new transfer into the same WH/INT/000001 (adding quantities or including the new product if it's different from the first transfer), losing the traceability of the source document. Is there a way to prevent this and have Odoo create as many transfers at the destination as were registered at the origin? 

Avatar
Descartar
Mejor respuesta

I had the same issue and I fixed it by overwriting the function below in stock_move.py. You may customise it to return the existing picking under certain conditions (purchase order, sale order) in order to keep the standard Odoo behaviour and merge all pending pickings into one.

So far it works for me but I can't say yet if there will be some downside. Pls comment with your findings.

I agree with you the automatic merging of pending picking by Odoo isn't making much sense, one could use batches to treat many pickings in one go

 

def _search_picking_for_assignation(self):
"""Override to prevent merging pickings, but keep logic for potential future conditions."""
self.ensure_one()
picking = super()._search_picking_for_assignation()

# Future logic can be added here (e.g., allow merging for sales orders)

return None
Avatar
Descartar
Mejor respuesta

Traceability back to the Source Document is managed in Odoo via Lot or Serial Number tracking of Products.


Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
0
feb 25
11
2
feb 25
2238
1
feb 19
3177
2
oct 18
9715
1
ago 15
10241