Ex: In a Child Doc a Link Field invoice
is linked to Doctype Purchase Invoice
.
If I select manually any Purchase Invoice
in the invoice
field it fetches values from the selected Purchase Invoice
and manupulates in the respective fields of the child table through Fetch From
Functionality.
But if I set value with frappe.model.set_value()
in the invoice
field with below code:
It does not trigger the fetch from functionality.
let child = frappe.model.add_child(frm.doc, <Child_Table_Field_Name>);
frappe.model.set_value(child.doctype, child.name, 'invoice', 'an_entity_of_purchase_invoice');
frm.refresh_field('Child_Table_Field_Nam')
Is it the normal behavior or am I not doing it properly?