Hello guys.
I created a custom button on form “Approve Movement” but i want it visible to User with Specific role “Warehouse manager”. below is what I have
//Make custom button Visible to user with specific role
frappe.ui.form.on(‘Request for Equipment’, {
validate: function(frm) {
if(role!=‘Equipment Manager’ ) {
frm.remove_custom_button(“Approve Movement”);
validated = false;
}
}
});
kindly help me out pls