文件管理、系统设置权限

This commit is contained in:
陈红丽 2024-07-29 09:46:37 +08:00
parent 0193c1f0d5
commit 5b78c3daf1
5 changed files with 14 additions and 39 deletions

View File

@ -13,7 +13,7 @@
@selection-change="onSelectionChange" @selection-change="onSelectionChange"
> >
<template #tableTitle> <template #tableTitle>
<el-button type="primary" @click="handleAdd"> <el-button type="primary" @click="handleAdd" v-perm="['sys:emailTemplate:add']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Plus /> <Plus />
@ -21,7 +21,7 @@
</template> </template>
添加 添加
</el-button> </el-button>
<el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length"> <el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length" v-perm="['sys:emailTemplate:batchDelete']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Delete /> <Delete />
@ -80,21 +80,13 @@ const editVisible=ref(false)
label: '编辑', label: '编辑',
type: 'warning', type: 'warning',
onClick: handleEdit.bind(null, record), onClick: handleEdit.bind(null, record),
ifShow: () => { auth: ['sys:emailTemplate:update'],
return true;
},
// auth: ['sys:fileLog:detail'],
}, },
{ {
label: '删除', label: '删除',
type: 'danger', type: 'danger',
onClick: handleDelete.bind(null, record), onClick: handleDelete.bind(null, record),
// isShow auth auth: ['sys:emailTemplate:delete'],
ifShow: () => {
return true;
},
// :
// auth: ['basic_list'],
}, },
], ],
}); });

View File

@ -13,7 +13,7 @@
@selection-change="onSelectionChange" @selection-change="onSelectionChange"
> >
<template #tableTitle> <template #tableTitle>
<el-button type="primary" @click="handleAdd"> <el-button type="primary" @click="handleAdd" v-perm="['sys:fileTemplate:add']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Plus /> <Plus />
@ -21,7 +21,7 @@
</template> </template>
添加 添加
</el-button> </el-button>
<el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length"> <el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length" v-perm="['sys:fileTemplate:batchDelete']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Delete /> <Delete />
@ -79,21 +79,13 @@ const editVisible=ref(false)
label: '编辑', label: '编辑',
type: 'warning', type: 'warning',
onClick: handleEdit.bind(null, record), onClick: handleEdit.bind(null, record),
ifShow: () => { auth: ['sys:fileTemplate:update'],
return true;
},
// auth: ['sys:fileLog:detail'],
}, },
{ {
label: '删除', label: '删除',
type: 'danger', type: 'danger',
onClick: handleDelete.bind(null, record), onClick: handleDelete.bind(null, record),
// isShow auth auth: ['sys:fileTemplate:delete'],
ifShow: () => {
return true;
},
// :
// auth: ['basic_list'],
}, },
], ],
}); });

View File

@ -13,7 +13,7 @@
@selection-change="onSelectionChange" @selection-change="onSelectionChange"
> >
<template #tableTitle> <template #tableTitle>
<el-button type="primary" @click="handleAdd"> <el-button type="primary" @click="handleAdd" v-perm="['sys:smsTemplate:add']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Plus /> <Plus />
@ -21,7 +21,7 @@
</template> </template>
添加 添加
</el-button> </el-button>
<el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length"> <el-button type="danger" @click="handleDelete()" :disabled="!selectionData.length" v-perm="['sys:smsTemplate:batchDelete']">
<template #icon> <template #icon>
<el-icon class="el-input__icon"> <el-icon class="el-input__icon">
<Delete /> <Delete />
@ -80,21 +80,12 @@ const editVisible=ref(false)
label: '编辑', label: '编辑',
type: 'warning', type: 'warning',
onClick: handleEdit.bind(null, record), onClick: handleEdit.bind(null, record),
ifShow: () => { auth: ['sys:smsTemplate:update'],
return true;
},
// auth: ['sys:fileLog:detail'],
}, },
{ {
label: '删除', label: '删除',
type: 'danger', type: 'danger',
onClick: handleDelete.bind(null, record), auth: ['sys:smsTemplate:delete'],
// isShow auth
ifShow: () => {
return true;
},
// :
// auth: ['basic_list'],
}, },
], ],
}); });

View File

@ -67,7 +67,7 @@
</el-col> </el-col>
</el-row> </el-row>
<div class="submit-btn"> <div class="submit-btn">
<el-button type="primary" @click="handleSubmit">更新系统设置</el-button> <el-button type="primary" @click="handleSubmit" v-perm="['sys:configWeb:save']">更新系统设置</el-button>
</div> </div>
</div> </div>
</template> </template>

View File

@ -55,7 +55,7 @@
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-space> <el-space>
<el-button :loading="subLoading" type="primary" @click="submit">更新基本信息</el-button> <el-button :loading="subLoading" type="primary" @click="submit" v-perm="['sys:profile:update']">更新基本信息</el-button>
</el-space> </el-space>
</el-form-item> </el-form-item>
</el-form> </el-form>