Try ERPNext Buy Support Partners Foundation

Routing - bom.js and routing.js conflict on v12

Hi there,

I notice there is an error with routing when you try to create the routing from bill of material (BOM).

Let’s say if you create an BOM and while creating a BOM, you hit “with operation”, and then it allow you to select routing, and then in the list you chose to create a new routing and then you jump over to routing. From there when you’re adding in operations, after you enter in a warehouse a message pops up and says:

Field “total_cost” not found

It doesn’t happens when you access new routing direct without access new BOM.

I was looking the errors and seems that it’s using bom.js functions instead routing.js functions, I think it’s a conflict because the BOM Operation is present in both files.

// fields: operation, workstation, operations_remove
frappe.ui.form.on("BOM Operation", "field", function() {

Same issue here.