Hi,
I am trying to create a javascript js file in a doctype and I am unable to get the values from the different doctype. Here is the sample of the code:
frappe.ui.form.on('Custom Doctype Name', 'field_name_on_change_this_code_is_executed', function(frm){
var check = frappe.db.get_value('Doctype_IN_ERPNext', 'nameofdocument', 'field_name')
console.log(check)
});
Now the problem is that the value of the check is coming out to be an object instead of just a value.
Sorry for my limited knowledge in js scripting since I am expecting a result as per python scripting.