ERPNext Foundation ERPNext Cloud Chat Blog Discuss Frappé* Donate

Pass field value to Stock Entry Detail


#1

I want to pass field value from “Material Request”:“m_cost_center” to “Stock Entry Detail”:“cost_center” using client custom script (Stock Entry Detail doctype) but it is not working.

cur_frm.add_fetch(“material_request”, “m_cost_center”, “cost_center”);

I need some help, thanks.


#2

cur_frm.add_fetch("[LINK FIELD]", “[SOURCE]”, “[TARGET]”);
eg:
cur_frm.add_fetch(“item_code”, “m_cost_center”, “cost_center”);

Check this Custom script - fetch data