提交
This commit is contained in:
1 parent
2df2ef0808
commit
683f14828f
388 files changed
+2738488
-81306
No files matched your search
@@ -329,12 +329,12 @@ async function handleDynamicRoutes(
|
||||
// 7. 验证工作标签页
|
||||
useWorktabStore().validateWorktabs(router)
|
||||
|
||||
// 7.5 冷登录:按收藏预开 Tab,落点首页
|
||||
// 7.5 冷登录:按收藏预开 Tab;有收藏则落点第一个收藏页,否则首页
|
||||
const userStore = useUserStore()
|
||||
const userId = String(userStore.info?.userId || '')
|
||||
let didPreopenFavorites = false
|
||||
const userId = String(userStore.info?.userId || userStore.info?.id || '')
|
||||
let preopenLandingPath: string | null = null
|
||||
try {
|
||||
didPreopenFavorites = await preopenFavoriteTabsIfNeeded(userId)
|
||||
preopenLandingPath = await preopenFavoriteTabsIfNeeded(userId)
|
||||
} catch (e) {
|
||||
console.warn('[RouteGuard] 预开收藏菜单失败:', e)
|
||||
}
|
||||
@@ -346,9 +346,9 @@ async function handleDynamicRoutes(
|
||||
if (isStaticRoute(to.path)) {
|
||||
routeInitInProgress = false
|
||||
next({
|
||||
path: didPreopenFavorites ? portalHome : to.path,
|
||||
query: didPreopenFavorites ? undefined : to.query,
|
||||
hash: didPreopenFavorites ? undefined : to.hash,
|
||||
path: preopenLandingPath || to.path,
|
||||
query: preopenLandingPath ? undefined : to.query,
|
||||
hash: preopenLandingPath ? undefined : to.hash,
|
||||
replace: true
|
||||
})
|
||||
return
|
||||
@@ -364,9 +364,9 @@ async function handleDynamicRoutes(
|
||||
// 初始化成功,重置进行中标记
|
||||
routeInitInProgress = false
|
||||
|
||||
// 9. 重新导航到目标路由(冷登录预开后强制首页)
|
||||
if (didPreopenFavorites) {
|
||||
next({ path: portalHome, replace: true })
|
||||
// 9. 重新导航到目标路由(冷登录预开后落点收藏首项或首页)
|
||||
if (preopenLandingPath) {
|
||||
next({ path: preopenLandingPath, replace: true })
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
@@ -310,6 +310,13 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
component: '/crm/quote/index',
|
||||
meta: { title: '报价单管理', keepAlive: true, menuCode: 'crm:quote:list' }
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000016',
|
||||
name: 'CrmQuoteApproval',
|
||||
path: 'quote-approval',
|
||||
component: '/crm/quote/approval/index',
|
||||
meta: { title: '报价单审批', keepAlive: true, menuCode: 'crm:quote:approve' }
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000015',
|
||||
name: 'CrmQuoteApproverSetting',
|
||||
@@ -322,6 +329,7 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
menuCode: 'crm:quote:approverSetting'
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
id: 'CRM3000000000000000000000000011',
|
||||
name: 'CrmQuoteForm',
|
||||
@@ -365,6 +373,13 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
component: '/crm/contract/index',
|
||||
meta: { title: '合同管理', keepAlive: true, menuCode: 'crm:contract:list' }
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000021',
|
||||
name: 'CrmContractApproval',
|
||||
path: 'contract-approval',
|
||||
component: '/crm/contract/approval/index',
|
||||
meta: { title: '合同审批', keepAlive: true, menuCode: 'crm:contract:approve' }
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000026',
|
||||
name: 'CrmContractApproverSetting',
|
||||
@@ -377,6 +392,7 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
menuCode: 'crm:contract:approverSetting'
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
id: 'CRM3000000000000000000000000030',
|
||||
name: 'CrmPriceLetter',
|
||||
@@ -385,7 +401,7 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
meta: { title: '调价函管理', keepAlive: true, menuCode: 'crm:priceLetter:list' }
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000021',
|
||||
id: 'CRM3000000000000000000000000027',
|
||||
name: 'CrmContractForm',
|
||||
path: 'contract/form',
|
||||
component: '/crm/contract/form',
|
||||
@@ -434,11 +450,11 @@ export const sqxpAdminRoutes: AppRouteRecord[] = [
|
||||
},
|
||||
{
|
||||
id: 'CRM3000000000000000000000000025',
|
||||
name: 'CrmContractApproval',
|
||||
name: 'CrmContractApprovalRecord',
|
||||
path: 'contract/approval',
|
||||
component: '/crm/contract/approval/index',
|
||||
component: '/crm/contract/approval-record/index',
|
||||
meta: {
|
||||
title: '合同审批',
|
||||
title: '合同审批记录',
|
||||
keepAlive: true,
|
||||
isHide: true,
|
||||
menuCode: 'crm:contract:approval:list'
|
||||
|
||||
Reference in new issue
Block a user