winterhazel commented on code in PR #8337:
URL: https://github.com/apache/cloudstack/pull/8337#discussion_r1430463427


##########
ui/src/config/section/user.js:
##########
@@ -96,6 +96,19 @@ export default {
           record.state === 'enabled'
       }
     },
+    {
+      api: 'lockUser',
+      icon: 'LockOutlined',
+      label: 'label.action.lock.user',
+      dataView: true,
+      popup: true,
+      show: (record, store) => {
+        return ['Admin', 'DomainAdmin'].includes(store.userInfo.roletype) && 
!record.isdefault &&
+          !(record.domain === 'ROOT' && record.account === 'admin' && 
record.accounttype === 1) &&
+          record.state === 'enabled'
+      },
+      component: shallowRef(defineAsyncComponent(() => 
import('@/views/iam/LockUser.vue')))

Review Comment:
   @DaanHoogland this seems like the optimal solution, as it would allow easily 
doing the same thing in other parts of the UI. Since this feature would prove 
useful to this PR, I will try implementing it here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to