diff --git a/erpnext/utilities/page/leaderboard/leaderboard.js b/erpnext/utilities/page/leaderboard/leaderboard.js index 1c085f2f5f..c5f2e8752d 100644 --- a/erpnext/utilities/page/leaderboard/leaderboard.js +++ b/erpnext/utilities/page/leaderboard/leaderboard.js @@ -85,7 +85,7 @@ frappe.Leaderboard = Class.extend({ this.$sidebar_list.on('click', 'li', function(e) { let $li = $(this); - let doctype = $li.find('span').html(); + let doctype = $li.find('span').attr("doctype-value"); me.options.selected_company = frappe.defaults.get_default('company'); me.options.selected_doctype = doctype; @@ -172,7 +172,7 @@ frappe.Leaderboard = Class.extend({ $container.find(".leaderboard-list").html(me.render_list_view(res.message)); } else { me.$graph_area.hide(); - me.message = "No items found."; + me.message = __("No items found."); $container.find(".leaderboard-list").html(me.render_list_view()); } }, @@ -301,7 +301,7 @@ frappe.Leaderboard = Class.extend({ get_sidebar_item: function(item) { return $(`
  • - ${ item } + ${ __(item) }
  • `); } });