|
|
@@ -279,10 +279,6 @@ export default {
|
|
|
{ title: '供应商管理', icon: 'el-icon-s-shop', perm: 'supply:manage',
|
|
|
children: [
|
|
|
{ path: '/supply-manage', label: '供应商管理', icon: 'el-icon-s-shop', perm: 'supply:manage' },
|
|
|
- { path: '/product-manage', label: '商品管理', icon: 'el-icon-s-goods', perm: 'commerce:products' },
|
|
|
- { path: '/product-edit', label: '商品编辑', icon: 'el-icon-edit', perm: 'commerce:products' },
|
|
|
- { path: '/category-manage', label: '商品分类', icon: 'el-icon-menu', perm: 'commerce:category' },
|
|
|
- { path: '/order-manage', label: '订单管理', icon: 'el-icon-s-order', perm: 'commerce:orders' },
|
|
|
]},
|
|
|
// --- 健康配置 ---
|
|
|
{ title: '健康配置', icon: 'el-icon-first-aid-kit', perm: 'system:config',
|
|
|
@@ -384,8 +380,8 @@ export default {
|
|
|
mounted() {
|
|
|
// 清除可能的 beforeunload 处理,防止页面刷新弹出"离开网站?"提示
|
|
|
window.onbeforeunload = null
|
|
|
- // 有消息权限(老师角色)才加载未读数
|
|
|
- if (hasPermission(this.effectivePerms, 'messages')) {
|
|
|
+ // 有消息权限(老师/营养师角色)才加载未读数,管理员不调用
|
|
|
+ if (hasPermission(this.effectivePerms, 'messages') && this.currentRole !== 'admin') {
|
|
|
this.fetchUnreadCount()
|
|
|
}
|
|
|
},
|