Hello,
Is it possible in the cloud version to fill the “Default warehouse” field based on the “Item Group”? If so, how?
Thanks,
Nuno
Hello,
Is it possible in the cloud version to fill the “Default warehouse” field based on the “Item Group”? If so, how?
Thanks,
Nuno
frappe.ui.form.on('Sales Order Item', 'item_code', function(frm, doctype, name) {
var row = frappe.get_doc(doctype, name);
if(row.item_group == 'A') row.warehouse = 'X';
if(row.item_group == 'B') row.warehouse = 'Y';
frm.refresh_field('items')
});
This topic was automatically closed after 24 hours. New replies are no longer allowed.