From 5ce83cbe638a836f9aec0b124a035a92d37d058b Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Tue, 3 Mar 2015 08:17:48 +0000 Subject: [PATCH] disable Manage Entities... button if no entities are defined. fixes #2704 --- static/js/documentsDialog.js | 1 + 1 file changed, 1 insertion(+) diff --git a/static/js/documentsDialog.js b/static/js/documentsDialog.js index 1164d3193..f340946cc 100644 --- a/static/js/documentsDialog.js +++ b/static/js/documentsDialog.js @@ -9,6 +9,7 @@ pandora.ui.documentsDialog = function() { // FIXME: user may not have the manage entites capability $switchButton = Ox.Button({ + disabled: !pandora.site.entities.length || !pandora.site.capabilities.canManageEntities[pandora.user.level], title: Ox._('Manage Entities...') }) .bindEvent({