WiP on permissions
Table of shares per user
This commit is contained in:
parent
89c9615592
commit
89256d62bd
20 changed files with 354 additions and 171 deletions
|
@ -15,24 +15,8 @@ function getAnonymousConfig(context) {
|
|||
}
|
||||
|
||||
function getAuthenticatedConfig(context) {
|
||||
const roles = {};
|
||||
for (const entityTypeId in config.roles) {
|
||||
const rolesPerEntityType = {};
|
||||
for (const roleId in config.roles[entityTypeId]) {
|
||||
const roleSpec = config.roles[entityTypeId][roleId];
|
||||
|
||||
rolesPerEntityType[roleId] = {
|
||||
name: roleSpec.name,
|
||||
description: roleSpec.description
|
||||
}
|
||||
}
|
||||
roles[entityTypeId] = rolesPerEntityType;
|
||||
}
|
||||
|
||||
|
||||
return {
|
||||
userId: context.user.id,
|
||||
roles
|
||||
userId: context.user.id
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue