How can I save the parent form if I change a field of child table?
frappe.ui.form.on('Child Table Name', {
item_name: function(frm, cdt, cdn) {
cur_frm.save();
}
});
by the way, it’s not a good solution to save form each time you change any field!
and how can we test that this field is not empty?
check bellow:
frappe.ui.form.on('Child Table Name', {
item_name: function(frm, cdt, cdn) {
var row = locals[cdt][cdn];
if(row.item_name){
cur_frm.save();
}
}
});