From 257db4099e840780385055219411d7222a47cbb1 Mon Sep 17 00:00:00 2001 From: Avris Date: Thu, 31 Dec 2020 00:03:30 +0100 Subject: [PATCH] #132 fine-grained permissions --- components/Account.vue | 2 +- components/Dictionary.vue | 6 +-- components/InclusiveDictionary.vue | 6 +-- components/Roles.vue | 62 ++++++++++++++++++++++++++++++ components/Source.vue | 2 +- components/TermsDictionary.vue | 6 +-- components/TermsSubmitForm.vue | 2 +- locale/en/translations.suml | 2 +- locale/pl/translations.suml | 2 +- migrations/015-permissions.sql | 9 +++++ plugins/auth.js | 9 +++-- routes/admin.vue | 59 ++++++++++++++++------------ routes/census.vue | 2 +- routes/sources.vue | 2 +- server/index.js | 4 +- server/routes/admin.js | 9 +++-- server/routes/inclusive.js | 12 +++--- server/routes/nouns.js | 14 +++---- server/routes/sources.js | 12 +++--- server/routes/terms.js | 12 +++--- server/routes/user.js | 2 +- src/helpers.js | 18 +++++++++ yarn.lock | 13 ++----- 23 files changed, 182 insertions(+), 85 deletions(-) create mode 100644 components/Roles.vue create mode 100644 migrations/015-permissions.sql diff --git a/components/Account.vue b/components/Account.vue index bd5cf3cd..14ba0fa6 100644 --- a/components/Account.vue +++ b/components/Account.vue @@ -26,7 +26,7 @@ -

+

user.account.admin

diff --git a/components/Dictionary.vue b/components/Dictionary.vue index 6cfb205f..7631d409 100644 --- a/components/Dictionary.vue +++ b/components/Dictionary.vue @@ -1,6 +1,6 @@