Hello, Guys Need Your Help…,
Wants to fetch all left as well as activate employees in Employee doctype.
I have written a custom script as follows…,
frappe.ui.form.on('Payment Entry', {
party_type:function(frm){
var abc = cur_frm.doc.party_type
console.log(abc);
if(abc=="Employee"){
frappe.call({
method: "frappe.client.get_list",
args: {
doctype: "Employee",
filters: [
["status", "=", "active"],
],
fields:["*"],
},
callback: function (r) {
if (r.message) {
console.log("In Response")
console.log(r.message)
}
}
})
}
}
})
But it will return only active employees i want all employees like status = active or status = left also…how to do this.