What is wrong here? Any idea why row.item_code is undefined.
I’m to get the item_code when I add a new line to grab other information in the db from the item_code.
frappe.ui.form.on('Purchase Order Item', {
item_code(frm, cdt, cdn) {
console.log("Item code");
var row = frappe.get_doc(cdt, cdn);
console.log(row); // Good!
console.log(row.item_code); // Return undefined, why?
}
})