Do not show row context menu if results are empty

This commit is contained in:
Dan Sosedoff 2018-09-14 18:19:24 -05:00
parent 6ed3d5b501
commit 29d4b276e2
2 changed files with 6 additions and 4 deletions

File diff suppressed because one or more lines are too long

View File

@ -874,8 +874,10 @@ function bindTableHeaderMenu() {
scopes: "td",
target: "#results_row_menu",
before: function(e, element, target) {
// Enable menu for browsing table rows view only.
if ($("#results").data("mode") != "browse") {
var isEmpty = $("#results").hasClass("empty");
var isBrowsing = $("#results").data("mode") == "browse";
if (isEmpty || !isBrowsing) {
e.preventDefault();
this.closemenu();
return false;