-
- Downloads
[FIX] mrp_subcontracting: find MO on landed cost form
In case of subcontracting, it is not straightforward for a user to select the appropriate MO on the landed costs form. To reproduce the issue: (Need stock_landed_costs) 1. Create two products P_compo, P_finished - Storable - P_finished: - Add a vendor V 2. Create a BoM: - Product: P_finished - Type: Subcontracting - Subcontractors: V - Components: 1 x P_compo 3. Process a receipt R: - From: V - Operations: 1 x P 4. Open the form to create a landed cost 5. Set the Apply On to Manufacturing orders 6. Try to find R Error: There isn't any reference for R. There is actually the reference of the manufacturing order (for instance WH/SBC/00001) but the user can't know that this MO is related to R. A part of the solution is the partial backport of [1]. Thanks to this commit, the method `name_get` of the MO will include the name of the associated receipt in case of subcontracting. [1] 0e26ed69 OPW-3070543 closes odoo/odoo#109431 Signed-off-by:William Henrotin (whe) <whe@odoo.com>