Hi Team,
I am trying to add buttons to my customer doctype list view using below client script.
function ButtonFunction(listview) {
console.log(“ButtonFunction”);
frappe.msgprint(“ButtonFunction”);
}
frappe.listview_settings[‘Customer’] = {
refresh: function(listview) {
listview.page.add_inner_button(“myview”, function() {
ButtonFunction(listview);
});;
},
};
However, this code is not working for me any guidance on it please
Erpnext version - 15.60.0
avc
2
Hi @vipinazad-85:
Should work …
Any error on browser console?
Is your client script “Enabled”?
Hope this helps.
Hi @avc
this one is working with below code →
frappe.listview_settings[‘Customer’].refresh = function(listview) {
listview.page.add_menu_item((“Menu”));
listview.page.add_action_item((“Actions”));
listview.page.set_primary_action(‘Primary Button’);
listview.page.set_secondary_action(‘Secondary Button’);
listview.page.add_inner_button(“Inner Button”);
};
but my requirement is to creat button in all the rows not on page … I have created another post for the same.