feat: 项目管理 业务部门完成
This commit is contained in:
parent
be37f1e536
commit
af4eb34c4c
@ -103,19 +103,31 @@ const generateBreadcrumb = () => {
|
||||
})
|
||||
} else if (currentPath.includes('/projectDetail')) {
|
||||
// 特殊处理:项目详情页面(项目管理的子页面)
|
||||
// 现在使用独立的路由,直接根据路由名称判断父级
|
||||
let projectManagementPath = '/projectManagement'
|
||||
let projectManagementName = 'projectManagement'
|
||||
let projectManagementTitle = '项目管理'
|
||||
|
||||
// 如果是projectDetail2路由,则对应projectManagement2
|
||||
if (currentPath.includes('/projectDetail2')) {
|
||||
projectManagementPath = '/projectManagement2'
|
||||
projectManagementName = 'projectManagement2'
|
||||
}
|
||||
|
||||
// 添加项目管理(父级)
|
||||
breadcrumbList.value.push({
|
||||
title: '项目管理',
|
||||
path: '/projectManagement',
|
||||
name: 'projectManagement',
|
||||
meta: { title: '项目管理' }
|
||||
title: projectManagementTitle,
|
||||
path: projectManagementPath,
|
||||
name: projectManagementName,
|
||||
meta: { title: projectManagementTitle }
|
||||
})
|
||||
|
||||
// 添加项目填报(当前页)
|
||||
// 添加项目详情(当前页)
|
||||
const detailName = currentPath.includes('/projectDetail2') ? 'projectDetail2' : 'projectDetail'
|
||||
breadcrumbList.value.push({
|
||||
title: '项目详情',
|
||||
path: currentPath,
|
||||
name: 'projectDetail',
|
||||
name: detailName,
|
||||
meta: { title: '项目详情' }
|
||||
})
|
||||
}
|
||||
|
||||
@ -158,6 +158,7 @@ const routes = [
|
||||
parentRoute: 'projectManagement' // 用于在面包屑中建立父子关系
|
||||
}
|
||||
},
|
||||
// 项目详情 - 区县版本
|
||||
{
|
||||
path: '/projectDetail/:data?',
|
||||
name: 'projectDetail',
|
||||
@ -165,7 +166,7 @@ const routes = [
|
||||
meta: {
|
||||
title: '项目详情',
|
||||
breadcrumb: true,
|
||||
parentRoute: 'projectManagement' // 用于在面包屑中建立父子关系
|
||||
parentRoute: 'projectManagement' // 明确指定父级路由
|
||||
}
|
||||
},
|
||||
// 项目管理 - 业务部门
|
||||
@ -178,6 +179,17 @@ const routes = [
|
||||
breadcrumb: true
|
||||
}
|
||||
},
|
||||
// 项目详情 - 业务部门版本
|
||||
{
|
||||
path: '/projectDetail2/:data?',
|
||||
name: 'projectDetail2',
|
||||
component: () => import('../views/ProjectManagement_Rebuild/district/projectDetailPage.vue'),
|
||||
meta: {
|
||||
title: '项目详情',
|
||||
breadcrumb: true,
|
||||
parentRoute: 'projectManagement2' // 明确指定父级路由为projectManagement2
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
path: '/disasterManagement',
|
||||
|
||||
@ -196,6 +196,11 @@ export default () => {
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
// 记录访问的项目管理模块
|
||||
onMounted(() => {
|
||||
sessionStorage.setItem('lastVisitedProjectManagement', 'projectManagement2')
|
||||
})
|
||||
|
||||
const columns = [
|
||||
{
|
||||
prop: "districtName",
|
||||
@ -400,9 +405,9 @@ export default () => {
|
||||
// 跳转至详情页面
|
||||
const gotoDetaillPage = (row) => {
|
||||
router.push({
|
||||
name: 'projectDetail',
|
||||
name: 'projectDetail2',
|
||||
params: {
|
||||
data: encodeURIComponent(JSON.stringify(row.id)),
|
||||
data: encodeURIComponent(JSON.stringify(row.id))
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@ -167,6 +167,11 @@ export default () => {
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
// 记录访问的项目管理模块
|
||||
onMounted(() => {
|
||||
sessionStorage.setItem('lastVisitedProjectManagement', 'projectManagement')
|
||||
})
|
||||
|
||||
const columns = [
|
||||
{
|
||||
prop: "districtName",
|
||||
@ -354,8 +359,8 @@ export default () => {
|
||||
router.push({
|
||||
name: 'projectDetail',
|
||||
params: {
|
||||
data: encodeURIComponent(JSON.stringify(row.id)),
|
||||
}
|
||||
data: encodeURIComponent(JSON.stringify(row.id))
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user