From 166b566fde617716cd514cbd087ba6dde84f2f7c Mon Sep 17 00:00:00 2001 From: j Date: Thu, 3 Jun 2021 16:25:56 +0100 Subject: [PATCH] if user can edit metadata of item, should also be able to add annotations for that item. independent of canAddAnnotations rights --- static/js/editor.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/static/js/editor.js b/static/js/editor.js index bbe87b25..90558d63 100644 --- a/static/js/editor.js +++ b/static/js/editor.js @@ -4,6 +4,7 @@ pandora.ui.editor = function(data) { var ui = pandora.user.ui, rightsLevel = data.rightslevel, + canEdit = pandora.hasCapability('canEditMetadata') || data.editable, that = Ox.VideoAnnotationPanel({ annotationsCalendarSize: ui.annotationsCalendarSize, @@ -44,7 +45,7 @@ pandora.ui.editor = function(data) { itemName: pandora.site.itemName, layers: data.annotations.map(function(layer) { return Ox.extend({ - editable: layer.canAddAnnotations[pandora.user.level] + editable: layer.canAddAnnotations[pandora.user.level] || canEdit }, layer, { autocomplete: layer.type == 'entity' ? function(key, value, callback) {