'权限配置'

This commit is contained in:
张磊
2026-04-27 10:08:46 +08:00
parent 87f0cf30ad
commit 8d7ffe2c5f
3 changed files with 73 additions and 70 deletions
+1 -1
View File
@@ -48,6 +48,6 @@ export function getADdStoreList(data: any): AxiosPromise<any> {
return request({ return request({
url: '/admin/v1/store/index', url: '/admin/v1/store/index',
method: 'post', method: 'post',
data: { ...data, auth: CONFIG_DATA.storeListId } data: { ...data, auth: CONFIG_DATA.storeAddStoreListId }
}); });
} }
+3 -3
View File
@@ -64,7 +64,8 @@ export const CONFIG_DATA = {
storeEditId: 'store:edit', //门店编辑 storeEditId: 'store:edit', //门店编辑
storeDeleteId: 'store:delete', //门店删除 storeDeleteId: 'store:delete', //门店删除
storeListId: 'store:List', //门店列表 storeListId: 'store:List', //门店列表
storeAddId: 'store:addStore', //门店添加 storeAddId: 'store:addstore', //门店添加
storeAddStoreListId: 'store:addAccountStore', //添加门店时选择的门店列表
//隐私协议 //隐私协议
privacyListId: 'privacy:List', //隐私协议列表 privacyListId: 'privacy:List', //隐私协议列表
privacyEditId: 'privacy:edit', //隐私协议列表修改 privacyEditId: 'privacy:edit', //隐私协议列表修改
@@ -76,8 +77,7 @@ export const CONFIG_DATA = {
graphDescriptionEditId: 'graph:edit', //图谱说明编辑 graphDescriptionEditId: 'graph:edit', //图谱说明编辑
graphDescriptionDeleteId: 'graph:delete', //图谱说明删除 graphDescriptionDeleteId: 'graph:delete', //图谱说明删除
graphDescriptionAddId: 'graph:add', //图谱说明添加 graphDescriptionAddId: 'graph:add', //图谱说明添加
graphDescriptionCategoryListId:'graph:type',//图谱说明分类列表 graphDescriptionCategoryListId: 'graph:types' //图谱说明分类列表
// //权限组 // //权限组
// authorityListId: 'auth:list', //权限列表 // authorityListId: 'auth:list', //权限列表
+4 -1
View File
@@ -51,7 +51,8 @@
<template #default="{ row }"> <template #default="{ row }">
<div class="op-links"> <div class="op-links">
<el-button v-if="state.roleEdit" type="primary" link @click="handleEdit(row)">修改</el-button> <el-button v-if="state.roleEdit" type="primary" link @click="handleEdit(row)">修改</el-button>
<el-button v-if="state.roleDelete" type="primary" link @click="handleDelete(row)">删除</el-button> <el-button v-if="state.roleDelete" type="primary" link
@click="handleDelete(row)">删除</el-button>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
@@ -117,6 +118,7 @@ const state = reactive({
roleEdit: false, // 编辑权限 roleEdit: false, // 编辑权限
roleDelete: false, // 删除权限 roleDelete: false, // 删除权限
roleAuthList: false, // 授权列表查看权限 roleAuthList: false, // 授权列表查看权限
roleAddStoreList: false, // 添加门店时选择的门店列表权限
}); });
// 列表 // 列表
@@ -240,6 +242,7 @@ const init = async () => {
state.roleEdit = hasAuth(CONFIG_DATA.storeEditId); state.roleEdit = hasAuth(CONFIG_DATA.storeEditId);
state.roleDelete = hasAuth(CONFIG_DATA.storeDeleteId); state.roleDelete = hasAuth(CONFIG_DATA.storeDeleteId);
state.roleAuthList = hasAuth(CONFIG_DATA.sotreAuthListId); state.roleAuthList = hasAuth(CONFIG_DATA.sotreAuthListId);
state.roleAddStoreList = hasAuth(CONFIG_DATA.storeAddStoreListId);
if (!state.roleList) { if (!state.roleList) {
ElMessage.error('没有访问权限'); ElMessage.error('没有访问权限');