fix: 修复全局组织下更新、删除:用户、端点、端点规则、组织权限

This commit is contained in:
“huailei000” 2022-09-15 19:23:49 +08:00 committed by Jiangjie.Bai
parent bc366947f0
commit fe1e26957a
4 changed files with 5 additions and 1 deletions

View File

@ -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')
},

View File

@ -37,9 +37,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')
}
}
}

View File

@ -38,6 +38,7 @@ export default {
},
actions: {
formatterArgs: {
canUpdate: this.$hasPerm('terminal.change_endpointrule'),
updateRoute: 'EndpointRuleUpdate',
cloneRoute: 'EndpointRuleCreate'
}

View File

@ -115,6 +115,7 @@ export default {
actions: {
formatterArgs: {
hasDelete: hasDelete,
canUpdate: this.$hasPerm('users.change_user'),
extraActions: [
{
title: this.$t('users.Remove'),