From 5cb3ede0b4f441c2ca6e3647bb08dee3d4286603 Mon Sep 17 00:00:00 2001
From: Vitalii Lysak <v.lysak@dunice.net>
Date: Wed, 31 Aug 2022 16:17:26 +0300
Subject: SILABMC-282|283: upd rights for Operator and NoAccess rolse

---
 .../SecurityAndAccess/UserManagement/UserManagement.vue     | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

(limited to 'src/views/_sila/SecurityAndAccess/UserManagement/UserManagement.vue')

diff --git a/src/views/_sila/SecurityAndAccess/UserManagement/UserManagement.vue b/src/views/_sila/SecurityAndAccess/UserManagement/UserManagement.vue
index e65b00df..8c073224 100644
--- a/src/views/_sila/SecurityAndAccess/UserManagement/UserManagement.vue
+++ b/src/views/_sila/SecurityAndAccess/UserManagement/UserManagement.vue
@@ -5,7 +5,10 @@
       <b-col xl="9" class="text-right">
         <b-button
           variant="link"
-          :disabled="$store.getters['authentication/role'] === 'ReadOnly'"
+          :disabled="
+            $store.getters['authentication/role'] === 'ReadOnly' ||
+            $store.getters['authentication/role'] === 'Operator'
+          "
           @click="initModalSettings"
         >
           <icon-settings />
@@ -14,7 +17,10 @@
         <b-button
           variant="primary"
           data-test-id="userManagement-button-addUser"
-          :disabled="$store.getters['authentication/role'] === 'ReadOnly'"
+          :disabled="
+            $store.getters['authentication/role'] === 'ReadOnly' ||
+            $store.getters['authentication/role'] === 'Operator'
+          "
           @click="initModalUser(null)"
         >
           <icon-add />
@@ -75,7 +81,8 @@
               :title="action.title"
               :class="{
                 disabledDiv:
-                  $store.getters['authentication/role'] === 'ReadOnly' &&
+                  ($store.getters['authentication/role'] === 'ReadOnly' ||
+                    $store.getters['authentication/role'] === 'Operator') &&
                   (action.value === 'delete' || action.value === 'edit'),
               }"
               @click-table-action="onTableRowAction($event, item)"
-- 
cgit v1.2.3

