Skip to content

Commit

Permalink
fix: 修复全局组织下更新、删除:用户、端点、端点规则、组织权限
Browse files Browse the repository at this point in the history
  • Loading branch information
huailei000 authored and BaiJiangJie committed Sep 26, 2022
1 parent 7f34195 commit c599a6a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/views/settings/Org/OrganizationList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ export default {
actions: {
prop: 'id',
formatterArgs: {
canUpdate: this.$hasPerm('orgs.change_organization'),
canDelete: function({ row }) {
return !row.is_default && vm.$hasPerm('orgs.delete_organization')
},
Expand Down
3 changes: 2 additions & 1 deletion src/views/settings/Terminal/Endpoint/EndpointList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,10 @@ export default {
},
actions: {
formatterArgs: {
canUpdate: this.$hasPerm('terminal.change_endpoint'),
updateRoute: 'EndpointUpdate',
cloneRoute: 'EndpointCreate',
canDelete: ({ row }) => row.id !== '00000000-0000-0000-0000-000000000001'
canDelete: ({ row }) => row.id !== '00000000-0000-0000-0000-000000000001' && this.$hasPerm('terminal.delete_endpoint')
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ export default {
},
actions: {
formatterArgs: {
canUpdate: this.$hasPerm('terminal.change_endpointrule'),
updateRoute: 'EndpointRuleUpdate',
cloneRoute: 'EndpointRuleCreate'
}
Expand Down
1 change: 1 addition & 0 deletions src/views/users/User/UserList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ export default {
actions: {
formatterArgs: {
hasDelete: hasDelete,
canUpdate: this.$hasPerm('users.change_user'),
extraActions: [
{
title: this.$t('users.Remove'),
Expand Down

0 comments on commit c599a6a

Please sign in to comment.