diff --git a/pandora/config.indiancinema.jsonc b/pandora/config.indiancinema.jsonc index cc70658b..f63b6e0b 100644 --- a/pandora/config.indiancinema.jsonc +++ b/pandora/config.indiancinema.jsonc @@ -350,6 +350,20 @@ } ], /* + "documentRightsLevel" defines which initial rights level will be assigned to documents + created by users of these user levels. + */ + "documentRightsLevel": {"member": 0, "researcher": 0, "staff": 0, "admin": 0}, + /* + "documentRightsLevels" is an ordered list of rights levels, one of which will be + assigned to each document. + */ + "documentRightsLevels": [ + {"name": "Public", "color": [128, 255, 128]}, + {"name": "Restricted", "color": [255, 212, 128]}, + {"name": "Private", "color": [255, 128, 128]} + ], + /* "entities" can be used to store arbitrary data. They can be referenced in annotations, info view, or elsewhere. Each entry defines a specific class of entity object, its properties and their types (for example an "actor" diff --git a/pandora/config.pandora.jsonc b/pandora/config.pandora.jsonc index 3fdb7edd..4b67f730 100644 --- a/pandora/config.pandora.jsonc +++ b/pandora/config.pandora.jsonc @@ -352,6 +352,20 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. } ], /* + "documentRightsLevel" defines which initial rights level will be assigned to documents + created by users of these user levels. + */ + "documentRightsLevel": {"member": 0, "researcher": 0, "staff": 0, "admin": 0}, + /* + "documentRightsLevels" is an ordered list of rights levels, one of which will be + assigned to each document. + */ + "documentRightsLevels": [ + {"name": "Public", "color": [128, 255, 128]}, + {"name": "Restricted", "color": [255, 212, 128]}, + {"name": "Private", "color": [255, 128, 128]} + ], + /* "entities" can be used to store arbitrary data. They can be referenced in annotations, info view, or elsewhere. Each entry defines a specific class of entity object, its properties and their types (for example an "actor" diff --git a/static/js/documentInfoView.js b/static/js/documentInfoView.js index 79476edd..ec4839d8 100644 --- a/static/js/documentInfoView.js +++ b/static/js/documentInfoView.js @@ -375,7 +375,7 @@ pandora.ui.documentInfoView = function(data) { function getRightsLevelElement(rightsLevel) { return Ox.Theme.formatColorLevel( rightsLevel, - pandora.site.rightsLevels.map(function(rightsLevel) { + pandora.site.documentRightsLevels.map(function(rightsLevel) { return rightsLevel.name; }) ); @@ -501,7 +501,7 @@ pandora.ui.documentInfoView = function(data) { $rightsLevel.empty(); if (canEdit) { $rightsLevelSelect = Ox.Select({ - items: pandora.site.rightsLevels.map(function(rightsLevel, i) { + items: pandora.site.documentRightsLevels.map(function(rightsLevel, i) { return {id: i, title: rightsLevel.name}; }), width: 128,