Browse Source

修改 bug

master
王泽彦 8 months ago
parent
commit
00b63dd920
  1. 24
      admin/src/app/api/auth.ts
  2. 68
      admin/src/app/views/auth/components/edit-role.vue
  3. 11
      admin/yarn.lock
  4. 7
      niucloud/app/service/admin/personnel/PersonnelService.php
  5. 7
      niucloud/app/service/admin/sys/MenuService.php
  6. 61
      niucloud/app/service/admin/uniapp/UniappAuthService.php
  7. 91
      uniapp/pages/common/home/index.vue

24
admin/src/app/api/auth.ts

@ -45,3 +45,27 @@ export function getLoginConfig() {
export function getVersions() { export function getVersions() {
return request.get(`sys/info`) return request.get(`sys/info`)
} }
/**
* UniApp菜单权限列表
*/
export function getUniappMenus() {
return request.get('uniapp_auth/menus')
}
/**
* UniApp菜单权限
* @param roleId ID
*/
export function getRoleUniappMenus(roleId: number) {
return request.get(`uniapp_auth/role_menus/${roleId}`)
}
/**
* UniApp菜单权限
* @param roleId ID
* @param menuIds ID数组
*/
export function setRoleUniappMenus(roleId: number, menuIds: number[]) {
return request.post(`uniapp_auth/set_role_menus/${roleId}`, { menu_ids: menuIds })
}

68
admin/src/app/views/auth/components/edit-role.vue

@ -141,7 +141,7 @@ import {
getWithDepartmentsList} from '@/app/api/departments' getWithDepartmentsList} from '@/app/api/departments'
import type {FormInstance} from 'element-plus' import type {FormInstance} from 'element-plus'
import {addRole, editRole, getRoleInfo} from '@/app/api/sys' import {addRole, editRole, getRoleInfo} from '@/app/api/sys'
import {getAuthMenus} from '@/app/api/auth' import {getAuthMenus, getUniappMenus, getRoleUniappMenus, setRoleUniappMenus} from '@/app/api/auth'
import {useDictionary} from '@/app/api/dict' import {useDictionary} from '@/app/api/dict'
import {debounce} from '@/utils/common' import {debounce} from '@/utils/common'
@ -163,16 +163,9 @@ getAuthMenus({is_button: 0}).then((res) => {
// UniApp // UniApp
const getMobileMenus = async () => { const getMobileMenus = async () => {
try { try {
// 使UniApp const res = await getUniappMenus()
const response = await fetch('http://localhost:20080/adminapi/uniapp_auth/menus', { if (res.data) {
headers: { mobileMenus.value = res.data.map(item => ({
'Content-Type': 'application/json',
'token': localStorage.getItem('token') || ''
}
})
const result = await response.json()
if (result.code === 1) {
mobileMenus.value = result.data.map(item => ({
menu_key: item.menu_key, menu_key: item.menu_key,
menu_name: item.menu_name, menu_name: item.menu_name,
id: item.id, id: item.id,
@ -195,11 +188,13 @@ const selectAllPC = ref(false)
const checkStrictlyPC = ref(false) const checkStrictlyPC = ref(false)
const treeRefPC: Record<string, any> | null = ref(null) const treeRefPC: Record<string, any> | null = ref(null)
watch(selectAllPC, () => { watch(selectAllPC, () => {
if (treeRefPC.value) {
if (selectAllPC.value) { if (selectAllPC.value) {
treeRefPC.value.setCheckedNodes(toRaw(menus.value)) treeRefPC.value.setCheckedNodes(toRaw(menus.value))
} else { } else {
treeRefPC.value.setCheckedNodes([]) treeRefPC.value.setCheckedNodes([])
} }
}
}) })
// //
@ -207,11 +202,13 @@ const selectAllMobile = ref(false)
const checkStrictlyMobile = ref(false) const checkStrictlyMobile = ref(false)
const treeRefMobile: Record<string, any> | null = ref(null) const treeRefMobile: Record<string, any> | null = ref(null)
watch(selectAllMobile, () => { watch(selectAllMobile, () => {
if (treeRefMobile.value) {
if (selectAllMobile.value) { if (selectAllMobile.value) {
treeRefMobile.value.setCheckedNodes(toRaw(mobileMenus.value)) treeRefMobile.value.setCheckedNodes(toRaw(mobileMenus.value))
} else { } else {
treeRefMobile.value.setCheckedNodes([]) treeRefMobile.value.setCheckedNodes([])
} }
}
}) })
const parentDepartmentIdList = ref([] as any[]) const parentDepartmentIdList = ref([] as any[])
@ -230,7 +227,9 @@ getRolekeyDictList()
// PC // PC
const handleCheckChangePC = debounce((e) => { const handleCheckChangePC = debounce((e) => {
if (treeRefPC.value) {
formData.rules = treeRefPC.value.getCheckedKeys() formData.rules = treeRefPC.value.getCheckedKeys()
}
}) })
const menuActionPC = () => { const menuActionPC = () => {
@ -245,7 +244,9 @@ const menuActionPC = () => {
// //
const handleCheckChangeMobile = debounce((e) => { const handleCheckChangeMobile = debounce((e) => {
if (treeRefMobile.value) {
formData.mobile_rules = treeRefMobile.value.getCheckedKeys() formData.mobile_rules = treeRefMobile.value.getCheckedKeys()
}
}) })
const menuActionMobile = () => { const menuActionMobile = () => {
@ -260,37 +261,53 @@ const menuActionMobile = () => {
// PC // PC
const unFoldAllPC = (data: any) => { const unFoldAllPC = (data: any) => {
if (treeRefPC.value && treeRefPC.value.store) {
Object.keys(data).forEach((key: string | any) => { Object.keys(data).forEach((key: string | any) => {
if (treeRefPC.value.store.nodesMap[data[key].menu_key]) {
treeRefPC.value.store.nodesMap[data[key].menu_key].expanded = true treeRefPC.value.store.nodesMap[data[key].menu_key].expanded = true
}
if (data[key].children && data[key].children.length > 0) if (data[key].children && data[key].children.length > 0)
unFoldAllPC(data[key].children) unFoldAllPC(data[key].children)
}) })
} }
}
// PC // PC
const collapseAllPC = (data: any) => { const collapseAllPC = (data: any) => {
if (treeRefPC.value && treeRefPC.value.store) {
Object.keys(data).forEach((key: string | any) => { Object.keys(data).forEach((key: string | any) => {
if (treeRefPC.value.store.nodesMap[data[key].menu_key]) {
treeRefPC.value.store.nodesMap[data[key].menu_key].expanded = false treeRefPC.value.store.nodesMap[data[key].menu_key].expanded = false
}
if (data[key].children && data[key].children.length > 0) if (data[key].children && data[key].children.length > 0)
collapseAllPC(data[key].children) collapseAllPC(data[key].children)
}) })
} }
}
// //
const unFoldAllMobile = (data: any) => { const unFoldAllMobile = (data: any) => {
if (treeRefMobile.value && treeRefMobile.value.store) {
Object.keys(data).forEach((key: string | any) => { Object.keys(data).forEach((key: string | any) => {
if (treeRefMobile.value.store.nodesMap[data[key].menu_key]) {
treeRefMobile.value.store.nodesMap[data[key].menu_key].expanded = true treeRefMobile.value.store.nodesMap[data[key].menu_key].expanded = true
}
if (data[key].children && data[key].children.length > 0) if (data[key].children && data[key].children.length > 0)
unFoldAllMobile(data[key].children) unFoldAllMobile(data[key].children)
}) })
} }
}
// //
const collapseAllMobile = (data: any) => { const collapseAllMobile = (data: any) => {
if (treeRefMobile.value && treeRefMobile.value.store) {
Object.keys(data).forEach((key: string | any) => { Object.keys(data).forEach((key: string | any) => {
if (treeRefMobile.value.store.nodesMap[data[key].menu_key]) {
treeRefMobile.value.store.nodesMap[data[key].menu_key].expanded = false treeRefMobile.value.store.nodesMap[data[key].menu_key].expanded = false
}
if (data[key].children && data[key].children.length > 0) if (data[key].children && data[key].children.length > 0)
collapseAllMobile(data[key].children) collapseAllMobile(data[key].children)
}) })
} }
}
/** /**
* 表单数据 * 表单数据
*/ */
@ -342,7 +359,9 @@ const confirm = async (formEl: FormInstance | undefined) => {
const data = Object.assign({}, formData) const data = Object.assign({}, formData)
// PC // PC
if (treeRefPC.value) {
data.rules = data.rules.concat(treeRefPC.value.getHalfCheckedKeys()) data.rules = data.rules.concat(treeRefPC.value.getHalfCheckedKeys())
}
// //
if (treeRefMobile.value) { if (treeRefMobile.value) {
@ -351,20 +370,7 @@ const confirm = async (formEl: FormInstance | undefined) => {
// UniAppAPI // UniAppAPI
if (data.role_id && data.mobile_rules.length >= 0) { if (data.role_id && data.mobile_rules.length >= 0) {
try { try {
const mobileResponse = await fetch(`http://localhost:20080/adminapi/uniapp_auth/set_role_menus/${data.role_id}`, { await setRoleUniappMenus(data.role_id, data.mobile_rules)
method: 'POST',
headers: {
'Content-Type': 'application/json',
'token': localStorage.getItem('token') || ''
},
body: JSON.stringify({
menu_ids: data.mobile_rules
})
})
const mobileResult = await mobileResponse.json()
if (mobileResult.code !== 1) {
console.error('移动端权限设置失败:', mobileResult.msg)
}
} catch (error) { } catch (error) {
console.error('设置移动端权限失败:', error) console.error('设置移动端权限失败:', error)
} }
@ -399,15 +405,9 @@ const setFormData = async (row: any = null) => {
// //
let mobileRulesData = [] let mobileRulesData = []
try { try {
const mobileResponse = await fetch(`http://localhost:20080/adminapi/uniapp_auth/role_menus/${row.role_id}`, { const mobileRes = await getRoleUniappMenus(row.role_id)
headers: { if (mobileRes.data) {
'Content-Type': 'application/json', mobileRulesData = mobileRes.data.map(item => item.menu_key)
'token': localStorage.getItem('token') || ''
}
})
const mobileResult = await mobileResponse.json()
if (mobileResult.code === 1) {
mobileRulesData = mobileResult.data.map(item => item.menu_key)
} }
} catch (error) { } catch (error) {
console.error('获取移动端权限失败:', error) console.error('获取移动端权限失败:', error)

11
admin/yarn.lock

@ -226,10 +226,10 @@
resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.0.10.tgz" resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.0.10.tgz"
integrity sha512-ygEZ1mwPjcPo/OulhzLE7mtDrQBWI8vZzEWSNB2W/RNCRjoQGwbaK4N8lV4rid7Ts4qvySU3njMN7YCiSlSaTQ== integrity sha512-ygEZ1mwPjcPo/OulhzLE7mtDrQBWI8vZzEWSNB2W/RNCRjoQGwbaK4N8lV4rid7Ts4qvySU3njMN7YCiSlSaTQ==
"@esbuild/linux-x64@0.16.17": "@esbuild/darwin-x64@0.16.17":
version "0.16.17" version "0.16.17"
resolved "https://registry.npmmirror.com/@esbuild/linux-x64/-/linux-x64-0.16.17.tgz" resolved "https://registry.npmmirror.com/@esbuild/darwin-x64/-/darwin-x64-0.16.17.tgz"
integrity sha512-mdPjPxfnmoqhgpiEArqi4egmBAMYvaObgn4poorpUaqmvzzbvqbowRllQ+ZgzGVMGKaPkqUmPDOOFQRUFDmeUw== integrity sha512-2By45OBHulkd9Svy5IOCZt376Aa2oOkiE9QWUK9fe6Tb+WDr8hXL3dpqi+DeLiMed8tVXspzsTAvd0jUl96wmg==
"@eslint/eslintrc@^1.4.1": "@eslint/eslintrc@^1.4.1":
version "1.4.1" version "1.4.1"
@ -2040,6 +2040,11 @@ fs.realpath@^1.0.0:
resolved "https://registry.npmmirror.com/fs.realpath/-/fs.realpath-1.0.0.tgz" resolved "https://registry.npmmirror.com/fs.realpath/-/fs.realpath-1.0.0.tgz"
integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==
fsevents@~2.3.2:
version "2.3.3"
resolved "https://registry.npmmirror.com/fsevents/-/fsevents-2.3.3.tgz"
integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==
function-bind@^1.1.2: function-bind@^1.1.2:
version "1.1.2" version "1.1.2"
resolved "https://registry.npmmirror.com/function-bind/-/function-bind-1.1.2.tgz" resolved "https://registry.npmmirror.com/function-bind/-/function-bind-1.1.2.tgz"

7
niucloud/app/service/admin/personnel/PersonnelService.php

@ -49,7 +49,7 @@ class PersonnelService extends BaseAdminService
$search_model = $this->model->withSearch(["name", "gender", "phone", "address", "education", "employee_number", "status", "create_time"], $where)->field($field)->order($order); $search_model = $this->model->withSearch(["name", "gender", "phone", "address", "education", "employee_number", "status", "create_time"], $where)->field($field)->order($order);
$list = $this->pageQuery($search_model, function ($item) { $list = $this->pageQuery($search_model, function ($item) {
$CampusPersonRole = new CampusPersonRole(); $CampusPersonRole = new CampusPersonRole();
$item['is_role'] = 1; $item['is_role'] = 1; // 始终允许角色设置
$role = $CampusPersonRole->where(['person_id' => $item['id']])->find(); $role = $CampusPersonRole->where(['person_id' => $item['id']])->find();
if($role){ if($role){
$item['role_data'] = [ $item['role_data'] = [
@ -57,9 +57,10 @@ class PersonnelService extends BaseAdminService
'campus_id' => $role['campus_id'], 'campus_id' => $role['campus_id'],
'person_id' => $item['id'], 'person_id' => $item['id'],
'role_id' => $role['role_id'], 'role_id' => $role['role_id'],
'dept_id' => 0 'dept_id' => $role['dept_id']
]; ];
$item['is_role'] = $role['dept_id'] == 0 ? 1 : 0; // 移除dept_id限制,始终允许角色设置
$item['is_role'] = 1;
}else{ }else{
$item['role_data'] = [ $item['role_data'] = [
'id' => '', 'id' => '',

7
niucloud/app/service/admin/sys/MenuService.php

@ -159,6 +159,7 @@ class MenuService extends BaseAdminService
function() use ($menu_keys, $is_tree, $addon) { function() use ($menu_keys, $is_tree, $addon) {
$where = [ $where = [
[ 'menu_key', 'in', $menu_keys ], [ 'menu_key', 'in', $menu_keys ],
[ 'app_type', '=', 'admin' ] // 只获取管理端菜单,排除UniApp菜单
]; ];
$addons = get_site_addons(); $addons = get_site_addons();
$addons[] = ''; $addons[] = '';
@ -187,9 +188,6 @@ class MenuService extends BaseAdminService
$where[] = [ 'menu_key', 'not in', $delete_intersect ]; $where[] = [ 'menu_key', 'not in', $delete_intersect ];
} }
} }
if (!empty($app_type)) {
$where[] = [ 'app_type', '=', $app_type ];
}
return ( new SysMenu() )->where($where)->order('sort', 'desc')->select()->toArray(); return ( new SysMenu() )->where($where)->order('sort', 'desc')->select()->toArray();
}, },
self::$cache_tag_name self::$cache_tag_name
@ -218,7 +216,8 @@ class MenuService extends BaseAdminService
$cache_name, $cache_name,
function() use ($status, $is_tree, $is_button) { function() use ($status, $is_tree, $is_button) {
$where = [ $where = [
[ 'addon', 'in', array_merge([ '' ], get_site_addons()) ] [ 'addon', 'in', array_merge([ '' ], get_site_addons()) ],
[ 'app_type', '=', 'admin' ] // 只获取管理端菜单,排除UniApp菜单
]; ];
if ($status != 'all') { if ($status != 'all') {
$where[] = [ 'status', '=', $status ]; $where[] = [ 'status', '=', $status ];

61
niucloud/app/service/admin/uniapp/UniappAuthService.php

@ -26,19 +26,22 @@ class UniappAuthService extends BaseAdminService
*/ */
public function getAllMenus() public function getAllMenus()
{ {
$sql = "SELECT id, menu_key, menu_name, menu_icon, menu_path, menu_params, sort_order, status, description // 从UniApp员工端功能页面整理文档获取菜单数据,基于school_sys_menu表结构
FROM sys_menus $sql = "SELECT id, menu_key, menu_name, icon as menu_icon, router_path as menu_path,
WHERE status = 1 '' as menu_params, sort, status, menu_short_name as description
ORDER BY sort_order ASC, id ASC"; FROM school_sys_menu
WHERE status = 1 AND app_type = 'uniapp'
ORDER BY sort ASC, id ASC";
$list = Db::query($sql); $list = Db::query($sql);
// 处理参数 // 处理参数和数据转换
foreach ($list as &$item) { foreach ($list as &$item) {
if (!empty($item['menu_params'])) { // 设置空的menu_params
$item['menu_params'] = json_decode($item['menu_params'], true) ?? [];
} else {
$item['menu_params'] = []; $item['menu_params'] = [];
} // 确保字段存在
$item['menu_icon'] = $item['menu_icon'] ?? '';
$item['menu_path'] = $item['menu_path'] ?? '';
$item['sort_order'] = $item['sort'];
} }
return $list; return $list;
@ -51,20 +54,21 @@ class UniappAuthService extends BaseAdminService
*/ */
public function getRoleMenus(int $roleId) public function getRoleMenus(int $roleId)
{ {
$sql = "SELECT m.id, m.menu_key, m.menu_name, m.menu_icon, m.menu_path, m.menu_params, m.sort_order $sql = "SELECT m.id, m.menu_key, m.menu_name, m.icon as menu_icon,
m.router_path as menu_path, '' as menu_params, m.sort as sort_order
FROM role_menu_permissions rmp FROM role_menu_permissions rmp
LEFT JOIN sys_menus m ON rmp.menu_id = m.id LEFT JOIN school_sys_menu m ON rmp.menu_id = m.id
WHERE rmp.role_id = ? AND rmp.is_enabled = 1 WHERE rmp.role_id = ? AND rmp.is_enabled = 1
ORDER BY m.sort_order ASC"; ORDER BY m.sort ASC";
$menuList = Db::query($sql, [$roleId]); $menuList = Db::query($sql, [$roleId]);
// 处理参数 // 处理参数和数据转换
foreach ($menuList as &$item) { foreach ($menuList as &$item) {
if (!empty($item['menu_params'])) { // 设置空的menu_params
$item['menu_params'] = json_decode($item['menu_params'], true) ?? [];
} else {
$item['menu_params'] = []; $item['menu_params'] = [];
} // 确保字段存在
$item['menu_icon'] = $item['menu_icon'] ?? '';
$item['menu_path'] = $item['menu_path'] ?? '';
} }
return $menuList; return $menuList;
@ -73,10 +77,10 @@ class UniappAuthService extends BaseAdminService
/** /**
* 设置角色的UniApp菜单权限 * 设置角色的UniApp菜单权限
* @param int $roleId * @param int $roleId
* @param array $menuIds * @param array $menuKeys 菜单键名数组(如:pages-common/my_attendance)
* @return bool * @return bool
*/ */
public function setRoleMenus(int $roleId, array $menuIds) public function setRoleMenus(int $roleId, array $menuKeys)
{ {
Db::startTrans(); Db::startTrans();
try { try {
@ -84,6 +88,24 @@ class UniappAuthService extends BaseAdminService
Db::execute("DELETE FROM role_menu_permissions WHERE role_id = ?", [$roleId]); Db::execute("DELETE FROM role_menu_permissions WHERE role_id = ?", [$roleId]);
// 添加新权限 // 添加新权限
if (!empty($menuKeys)) {
// 将menu_key转换为对应的数据库ID
$menuIds = [];
$sql = "SELECT id, menu_key FROM school_sys_menu WHERE app_type = 'uniapp' AND status = 1";
$menuList = Db::query($sql);
$menuKeyToId = [];
foreach ($menuList as $menu) {
$menuKeyToId[$menu['menu_key']] = $menu['id'];
}
// 过滤出有效的菜单ID
foreach ($menuKeys as $menuKey) {
if (isset($menuKeyToId[$menuKey])) {
$menuIds[] = $menuKeyToId[$menuKey];
}
}
// 插入新的权限数据
if (!empty($menuIds)) { if (!empty($menuIds)) {
$values = []; $values = [];
$params = []; $params = [];
@ -95,6 +117,7 @@ class UniappAuthService extends BaseAdminService
$sql = "INSERT INTO role_menu_permissions (role_id, menu_id, is_enabled, created_at, updated_at) VALUES " . implode(', ', $values); $sql = "INSERT INTO role_menu_permissions (role_id, menu_id, is_enabled, created_at, updated_at) VALUES " . implode(', ', $values);
Db::execute($sql, $params); Db::execute($sql, $params);
} }
}
Db::commit(); Db::commit();
return true; return true;

91
uniapp/pages/common/home/index.vue

@ -26,7 +26,7 @@
<view class="grid-content"> <view class="grid-content">
<view <view
class="grid-item" class="grid-item"
v-for="(item, index) in gridItems" v-for="(item, index) in visibleGridItems"
:key="index" :key="index"
@click="handleGridClick(item)" @click="handleGridClick(item)"
> >
@ -45,18 +45,81 @@
data() { data() {
return { return {
userInfo: {}, userInfo: {},
gridItems: [], userPermissions: [], //
defaultGridItems: [ // /
allGridItems: [
{
title: '客户资源',
icon: 'person-filled',
path: '/pages/market/clue/index'
},
{
title: '添加资源',
icon: 'plus-filled',
path: '/pages/market/clue/add_clues'
},
{
title: '数据统计',
icon: 'bars',
path: '/pages/market/data/statistics'
},
{
title: '个人中心',
icon: 'person',
path: '/pages/market/my/index'
},
{
title: '首页',
icon: 'home',
path: '/pages/market/home/index'
},
{
title: '课程安排',
icon: 'calendar-filled',
path: '/pages-market/clue/class_arrangement'
},
{
title: '学员管理',
icon: 'person',
path: '/pages-coach/coach/student/student_list'
},
{
title: '课程查询',
icon: 'list',
path: '/pages-coach/coach/schedule/schedule_table'
},
{ {
title: '我的数据', title: '我的数据',
icon: 'bars', icon: 'bars',
path: '/pages/common/dashboard/webview', path: '/pages/common/dashboard/webview',
params: { type: 'my_data' } params: { type: 'my_data' }
}, },
{
title: '部门数据',
icon: 'home',
path: '/pages/common/dashboard/webview',
params: { type: 'dept_data' }
},
{
title: '校区数据',
icon: 'location',
path: '/pages/common/dashboard/webview',
params: { type: 'campus_data' }
},
{ {
title: '我的消息', title: '我的消息',
icon: 'chat-filled', icon: 'chat-filled',
path: '/pages-common/my_message' path: '/pages/common/my/my_message'
},
{
title: '报销管理',
icon: 'wallet-filled',
path: '/pages-market/reimbursement/list'
},
{
title: '资料库',
icon: 'folder-add',
path: '/pages-coach/coach/my/teaching_management'
} }
] ]
} }
@ -69,6 +132,14 @@
// //
this.loadMenuList(); this.loadMenuList();
}, },
computed: {
//
visibleGridItems() {
return this.allGridItems.filter(item => {
return this.userPermissions.includes(item.path);
});
}
},
methods: { methods: {
loadUserInfo() { loadUserInfo() {
// //
@ -83,13 +154,15 @@
console.log('从本地存储获取的菜单列表:', menuList); console.log('从本地存储获取的菜单列表:', menuList);
if (menuList && Array.isArray(menuList) && menuList.length > 0) { if (menuList && Array.isArray(menuList) && menuList.length > 0) {
// 使 // path
this.gridItems = menuList; this.userPermissions = menuList.map(item => item.path);
} else { } else {
// 使 //
this.gridItems = this.defaultGridItems; this.userPermissions = ['/pages/common/dashboard/webview', '/pages-common/my_message'];
console.log('使用默认菜单'); console.log('使用默认权限');
} }
console.log('用户权限路径:', this.userPermissions);
}, },
handleGridClick(item) { handleGridClick(item) {
console.log('点击功能按钮:', item.title, item.path); console.log('点击功能按钮:', item.title, item.path);

Loading…
Cancel
Save