This commit is contained in:
2026-11-03 17:15:03 +08:00
parent 1afc7034cd
commit 01d0a81603
4 changed files with 50 additions and 16 deletions
+3 -2
View File
@@ -53,10 +53,10 @@ describe('adminNavigation', () => {
{ title: '财务管理', children: ['海外费用明细', '客户账户', '客户应收应付', '应收款统计表', '客户对账单', '结算单应收', '结算单应付'] },
{ title: '海外仓', children: ['经营总览', '销量分析', '库存分析', '数据采集'] },
{ title: '通用', children: ['费用项目', '汇率管理', '仓库管理', '海外仓报价', '车队报价', '船期价格表', '下载中心', '供应商列表'] },
{ title: '系统管理', children: ['用户管理', '角色权限', '菜单权限'] },
{ title: '系统管理', children: ['用户管理', '角色权限', '菜单权限', 'PDA版本'] },
])
expect(visible).toHaveLength(13)
expect(visible.flatMap(node => node.children ?? [])).toHaveLength(60)
expect(visible.flatMap(node => node.children ?? [])).toHaveLength(61)
expect(adminNavigation.find((item) => item.key === 'notifications')).toBeUndefined()
})
@@ -172,6 +172,7 @@ describe('adminNavigation', () => {
const paths = getNavigationLeaves(filtered).map((item) => item.path)
expect(paths).toContain('/system/permissions')
expect(paths).not.toContain('/prototype/finance/profit-report')
expect(paths).not.toContain('/system/pda-releases')
expect(paths).not.toContain('/notifications/messages')
expect(paths).not.toContain('/customers')
expect(filtered.map((item) => item.title)).toEqual(['首页数据看板', '系统管理'])