明树Git Lab

Commit d7b10ba8 authored by zhanghan's avatar zhanghan

完成项目档案库开发

parent ffdc2ddb
Pipeline #109390 passed with stage
in 21 seconds
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
## 功能说明 ## 功能说明
这是一个基于 Element Plus `el-collapse` 的粘性导航组件,可以自动为折叠面板生成右侧导航,支持: 这是一个基于 Element Plus `el-collapse` 的粘性导航组件,可以自动为折叠面板生成右侧导航,支持:
- 自动获取所有折叠面板项 - 自动获取所有折叠面板项
- 点击导航快速定位到对应面板 - 点击导航快速定位到对应面板
- 滚动时自动高亮当前可见的面板 - 滚动时自动高亮当前可见的面板
...@@ -42,10 +43,10 @@ ...@@ -42,10 +43,10 @@
</template> </template>
<script setup> <script setup>
import { ref } from 'vue'; import { ref } from "vue";
import CollapseNavigation from '@/components/CollapseNavigation/index.vue'; import CollapseNavigation from "@/components/CollapseNavigation/index.vue";
const activeCollapse = ref(['项目基本信息']); const activeCollapse = ref(["项目基本信息"]);
const navigationItems = ref([]); // 由指令自动填充 const navigationItems = ref([]); // 由指令自动填充
const handleNavClick = (item) => { const handleNavClick = (item) => {
...@@ -76,20 +77,20 @@ const handleNavClick = (item) => { ...@@ -76,20 +77,20 @@ const handleNavClick = (item) => {
## 组件 Props ## 组件 Props
| 参数 | 说明 | 类型 | 默认值 | | 参数 | 说明 | 类型 | 默认值 |
|------|------|------|--------| | --------------- | -------------- | ------------ | ----------- |
| navItems | 导航项列表 | Array | [] | | navItems | 导航项列表 | Array | [] |
| activeItem | 当前激活的项 | String/Array | '' | | activeItem | 当前激活的项 | String/Array | '' |
| width | 导航宽度 | String | '200px' | | width | 导航宽度 | String | '200px' |
| title | 导航标题 | String | '快速导航' | | title | 导航标题 | String | '快速导航' |
| scrollContainer | 滚动容器选择器 | String | '' (window) | | scrollContainer | 滚动容器选择器 | String | '' (window) |
| offset | 滚动偏移量 | Number | 0 | | offset | 滚动偏移量 | Number | 0 |
## 组件事件 ## 组件事件
| 事件名 | 说明 | 参数 | | 事件名 | 说明 | 参数 |
|--------|------|------| | ----------------- | ---------------- | ---------------- |
| navClick | 导航项被点击 | item: 导航项对象 | | navClick | 导航项被点击 | item: 导航项对象 |
| update:activeItem | 激活项变化时触发 | name: 导航项名称 | | update:activeItem | 激活项变化时触发 | name: 导航项名称 |
## 自定义指令 ## 自定义指令
...@@ -99,6 +100,7 @@ const handleNavClick = (item) => { ...@@ -99,6 +100,7 @@ const handleNavClick = (item) => {
自动获取 `el-collapse` 的所有子项并生成导航数据。 自动获取 `el-collapse` 的所有子项并生成导航数据。
**用法:** **用法:**
```vue ```vue
<el-collapse v-collapse-nav="navigationItems"> <el-collapse v-collapse-nav="navigationItems">
<!-- 折叠面板项 --> <!-- 折叠面板项 -->
...@@ -106,6 +108,7 @@ const handleNavClick = (item) => { ...@@ -106,6 +108,7 @@ const handleNavClick = (item) => {
``` ```
**参数:** **参数:**
- `navigationItems`: 响应式数组,用于接收生成的导航数据 - `navigationItems`: 响应式数组,用于接收生成的导航数据
## 高级配置 ## 高级配置
......
...@@ -1069,11 +1069,6 @@ const navigationItems = ref([]); ...@@ -1069,11 +1069,6 @@ const navigationItems = ref([]);
const handleNavClick = (item) => { const handleNavClick = (item) => {
console.log("Navigation clicked:", item); console.log("Navigation clicked:", item);
// 点击导航时自动展开对应的折叠面板
if (!activeCollapse.value.includes(item.name)) {
activeCollapse.value.push(item.name);
}
// 等待 DOM 更新后滚动 // 等待 DOM 更新后滚动
nextTick(() => { nextTick(() => {
setTimeout(() => { setTimeout(() => {
......
...@@ -530,6 +530,14 @@ import FinancialTable from "@/components/FinancialTable.vue"; ...@@ -530,6 +530,14 @@ import FinancialTable from "@/components/FinancialTable.vue";
import InvestmentRecoveryTable from "@/components/InvestmentRecoveryTable.vue"; import InvestmentRecoveryTable from "@/components/InvestmentRecoveryTable.vue";
import routerBack from "@/components/common/routerBack.vue"; import routerBack from "@/components/common/routerBack.vue";
import CollapseNavigation from "@/components/CollapseNavigation/index.vue"; import CollapseNavigation from "@/components/CollapseNavigation/index.vue";
// 接收父组件传递的 isPreview prop
const props = defineProps({
isPreview: {
type: Boolean,
default: undefined,
},
});
const transferColumns = ref([ const transferColumns = ref([
{ {
prop: "njfcgbl", prop: "njfcgbl",
...@@ -587,11 +595,6 @@ const navigationItems = ref([]); ...@@ -587,11 +595,6 @@ const navigationItems = ref([]);
const handleNavClick = (item) => { const handleNavClick = (item) => {
console.log("Navigation clicked:", item); console.log("Navigation clicked:", item);
// 点击导航时自动展开对应的折叠面板
if (!activeCollapse.value.includes(item.name)) {
activeCollapse.value.push(item.name);
}
// 等待 DOM 更新后滚动 // 等待 DOM 更新后滚动
nextTick(() => { nextTick(() => {
setTimeout(() => { setTimeout(() => {
...@@ -1288,8 +1291,15 @@ const changeProject = (val) => { ...@@ -1288,8 +1291,15 @@ const changeProject = (val) => {
}; };
// 加载状态 // 加载状态
const loading = ref(false); const loading = ref(false);
// 是否预览模式 // 是否预览模式 - 优先使用父组件传递的 prop,否则从路由参数读取
const isPreview = ref(!!route.query.isPreview); const isPreview = computed(() => {
// 如果父组件显式传递了 isPreview prop,使用 prop 的值
if (props.isPreview !== undefined) {
return props.isPreview;
}
// 否则从路由参数读取
return !!route.query.isPreview;
});
// 项目列表数据 // 项目列表数据
const projectList = ref([]); const projectList = ref([]);
// 当前编辑的记录ID // 当前编辑的记录ID
......
...@@ -87,6 +87,11 @@ ...@@ -87,6 +87,11 @@
<el-input v-model="jcFormData.tzms" /> <el-input v-model="jcFormData.tzms" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="原决策审批单位">
<el-input v-model="jcFormData.jcspdw" />
</el-form-item>
</el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="对外签约品牌"> <el-form-item label="对外签约品牌">
<el-input v-model="jcFormData.dwqypp" /> <el-input v-model="jcFormData.dwqypp" />
...@@ -596,7 +601,7 @@ ...@@ -596,7 +601,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="项目开工时间(预计)"> <el-form-item label="项目开工时间">
<el-date-picker <el-date-picker
v-model="jcFormData.xmkgsjyj" v-model="jcFormData.xmkgsjyj"
type="date" type="date"
...@@ -605,7 +610,7 @@ ...@@ -605,7 +610,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="项目交工时间(预计)"> <el-form-item label="项目交工时间">
<el-date-picker <el-date-picker
v-model="jcFormData.xmjgsjyj" v-model="jcFormData.xmjgsjyj"
type="date" type="date"
...@@ -613,6 +618,28 @@ ...@@ -613,6 +618,28 @@
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="运营起始时间">
<el-date-picker
v-model="jcFormData.yykssj"
type="date"
value-format="YYYY-MM-DD"
fomat="YYYY-MM-DD"
placeholder="请选择"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="运营结束时间">
<el-date-picker
v-model="jcFormData.yyjssj"
value-format="YYYY-MM-DD"
fomat="YYYY-MM-DD"
type="date"
placeholder="请选择"
/>
</el-form-item>
</el-col>
</el-row> </el-row>
</el-collapse-item> </el-collapse-item>
<el-collapse-item title="投资分类" name="投资分类"> <el-collapse-item title="投资分类" name="投资分类">
...@@ -1273,7 +1300,7 @@ ...@@ -1273,7 +1300,7 @@
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="yjzczb" prop="yjzczb"
label="应缴注册资本(万元)" label="应缴注册资本(万元)"
width="180" width="180"
> >
<template #default="scope"> <template #default="scope">
...@@ -1299,6 +1326,38 @@ ...@@ -1299,6 +1326,38 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
prop="yjzczbj"
label="已缴注册资本金(万元)"
width="180"
>
<template #default="scope">
<el-input-number
v-if="scope.$index < jcGdxxData.length - 1"
v-model="scope.row.yjzczbj"
:min="0"
:max="99999999999.99999999"
controls-position="right"
@change="changeJcGdxxSums"
/>
<div v-else class="sums-column">
<div
class=""
v-for="(value, key) in jcgdxxSums"
:key="key"
>
{{ (value.yjzczbj || 0).toFixed(2) }}万元
</div>
<div>
{{
(
getObjSums(jcgdxxSums, "yjzczbj") || 0
).toFixed(2)
}}万元
</div>
</div>
</template>
</el-table-column>
<el-table-column <el-table-column
prop="ycxmzbj" prop="ycxmzbj"
label="应出项目资本金(万元)" label="应出项目资本金(万元)"
...@@ -1327,6 +1386,38 @@ ...@@ -1327,6 +1386,38 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
prop="yjxmzbj"
label="已缴项目资本金(万元)"
width="180"
>
<template #default="scope">
<el-input-number
v-if="scope.$index < jcGdxxData.length - 1"
v-model="scope.row.yjxmzbj"
:min="0"
:max="99999999999.99999999"
controls-position="right"
@change="changeJcGdxxSums"
/>
<div v-else class="sums-column">
<div
class=""
v-for="(value, key) in jcgdxxSums"
:key="key"
>
{{ (value.yjxmzbj || 0).toFixed(2) }}万元
</div>
<div>
{{
(
getObjSums(jcgdxxSums, "yjxmzbj") || 0
).toFixed(2)
}}万元
</div>
</div>
</template>
</el-table-column>
<el-table-column <el-table-column
prop="sfwqcnsy" prop="sfwqcnsy"
label="是否为其承诺收益" label="是否为其承诺收益"
...@@ -1381,11 +1472,16 @@ ...@@ -1381,11 +1472,16 @@
<div v-else></div> <div v-else></div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="bz" label="备注" width="180">
<el-table-column
prop="yjzczbj"
label="备注"
width="180"
>
<template #default="scope"> <template #default="scope">
<el-input <el-input
v-if="scope.$index < jcGdxxData.length - 1" v-if="scope.$index < jcGdxxData.length - 1"
v-model="scope.row.bz" v-model="scope.row.yjzczbj"
/> />
<div v-else></div> <div v-else></div>
</template> </template>
...@@ -1633,20 +1729,17 @@ ...@@ -1633,20 +1729,17 @@
</el-col> </el-col>
</el-row> </el-row>
</el-collapse-item> </el-collapse-item>
<el-collapse-item <el-collapse-item title="项目实施现状" name="项目实施现状">
title="项目内容及必要性" <el-form-item label="投资完成情况">
name="项目内容及必要性"
>
<el-form-item label="项目必要性">
<el-input <el-input
v-model="jcFormData.xmbyx" v-model="jcFormData.tzwcqk"
type="textarea" type="textarea"
:autosize="{ minRows: 2, maxRows: 5 }" :autosize="{ minRows: 2, maxRows: 5 }"
/> />
</el-form-item> </el-form-item>
<el-form-item label="其他说明"> <el-form-item label="投资回收情况">
<el-input <el-input
v-model="jcFormData.qtsm" v-model="jcFormData.tzhsqk"
type="textarea" type="textarea"
:autosize="{ minRows: 2, maxRows: 5 }" :autosize="{ minRows: 2, maxRows: 5 }"
/> />
...@@ -2482,7 +2575,7 @@ ...@@ -2482,7 +2575,7 @@
/> />
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="决策批复" name="决策批复"> <el-tab-pane label="重新决策批复" name="重新决策批复">
<div class="tabBody"></div> <div class="tabBody"></div>
<div class="tab-content"> <div class="tab-content">
<el-form :model="jcFormData" :disabled="isPreview"> <el-form :model="jcFormData" :disabled="isPreview">
...@@ -3295,9 +3388,13 @@ ...@@ -3295,9 +3388,13 @@
isPreview && isPreview &&
canAudit && canAudit &&
(formData.projectLzType == '3' || (formData.projectLzType == '3' ||
formData.projectLzType == 3 ||
jcFormData.projectLzType == '8' || jcFormData.projectLzType == '8' ||
jcFormData.projectLzType == 8 ||
jcFormData.projectLzType == '11' || jcFormData.projectLzType == '11' ||
jcFormData.projectLzType == '12') && jcFormData.projectLzType == 11 ||
jcFormData.projectLzType == '12' ||
jcFormData.projectLzType == 12) &&
formData.del !== 1 formData.del !== 1
" "
> >
...@@ -3395,7 +3492,7 @@ const activeCollapse = reactive([ ...@@ -3395,7 +3492,7 @@ const activeCollapse = reactive([
"我方担保及股权融资情况", "我方担保及股权融资情况",
"我方担保及债权融资情况", "我方担保及债权融资情况",
"工程带动情况", "工程带动情况",
"项目内容及必要性", "项目实施现状",
"风险管理", "风险管理",
"里程碑节点", "里程碑节点",
"投评决策资料", "投评决策资料",
...@@ -3477,18 +3574,26 @@ const changeGdxxSums = () => { ...@@ -3477,18 +3574,26 @@ const changeGdxxSums = () => {
name: gdlxList.filter((gdlx) => gdlx.key == item.gdlx)[0].value, name: gdlxList.filter((gdlx) => gdlx.key == item.gdlx)[0].value,
}; };
} }
obj[item.gdlx].cgbl = new Decimal( obj[item.gdlx].cgbl = Number(
Number(obj[item.gdlx].cgbl || 0), new Decimal(Number(obj[item.gdlx].cgbl || 0)).plus(
).plus(new Decimal(Number(item.cgbl || 0))); new Decimal(Number(item.cgbl || 0)),
obj[item.gdlx].cze = new Decimal(Number(obj[item.gdlx].cze || 0)).plus( ),
new Decimal(Number(item.cze || 0)), );
obj[item.gdlx].cze = Number(
new Decimal(Number(obj[item.gdlx].cze || 0)).plus(
new Decimal(Number(item.cze || 0)),
),
);
obj[item.gdlx].yjzczb = Number(
new Decimal(Number(obj[item.gdlx].yjzczb || 0)).plus(
new Decimal(Number(item.yjzczb || 0)),
),
);
obj[item.gdlx].ycxmzbj = Number(
new Decimal(Number(obj[item.gdlx].ycxmzbj || 0)).plus(
new Decimal(Number(item.ycxmzbj || 0)),
),
); );
obj[item.gdlx].yjzczb = new Decimal(
Number(obj[item.gdlx].yjzczb || 0),
).plus(new Decimal(Number(item.yjzczb || 0)));
obj[item.gdlx].ycxmzbj = new Decimal(
Number(obj[item.gdlx].ycxmzbj || 0),
).plus(new Decimal(Number(item.ycxmzbj || 0)));
} }
} }
}); });
...@@ -3498,9 +3603,11 @@ const changeGdxxSums = () => { ...@@ -3498,9 +3603,11 @@ const changeGdxxSums = () => {
// 计算对象总和 // 计算对象总和
const getObjSums = (obj, objkey) => { const getObjSums = (obj, objkey) => {
return Object.entries(obj).reduce( return Number(
(acc, [key, item]) => acc.plus(new Decimal(item[objkey] || 0)), Object.entries(obj).reduce(
new Decimal(0), (acc, [key, item]) => acc.plus(new Decimal(item[objkey] || 0)),
new Decimal(0),
),
); );
}; };
// 支撑材料 // 支撑材料
...@@ -3730,29 +3837,54 @@ const changeJcGdxxSums = () => { ...@@ -3730,29 +3837,54 @@ const changeJcGdxxSums = () => {
let obj = {}; let obj = {};
jcGdxxData.forEach((item, index) => { jcGdxxData.forEach((item, index) => {
if (index < jcGdxxData.length - 1) { if (index < jcGdxxData.length - 1) {
if (!obj[item.gdlx]) { if (item.gdlx) {
obj[item.gdlx] = { if (!obj[item.gdlx]) {
name: gdlxList.filter((gdlx) => gdlx.key == item.gdlx)[0].value, const gdlxItem = gdlxList.filter((gdlx) => gdlx.key == item.gdlx)[0];
}; obj[item.gdlx] = {
name: gdlxItem ? gdlxItem.value : "",
};
}
obj[item.gdlx].mycgbl = Number(
new Decimal(Number(obj[item.gdlx].mycgbl || 0)).plus(
new Decimal(Number(item.mycgbl || 0)),
),
);
obj[item.gdlx].cgbl = Number(
new Decimal(Number(obj[item.gdlx].cgbl || 0)).plus(
new Decimal(Number(item.cgbl || 0)),
),
);
obj[item.gdlx].lrfpbl = Number(
new Decimal(Number(obj[item.gdlx].lrfpbl || 0)).plus(
new Decimal(Number(item.lrfpbl || 0)),
),
);
obj[item.gdlx].cze = Number(
new Decimal(Number(obj[item.gdlx].cze || 0)).plus(
new Decimal(Number(item.cze || 0)),
),
);
obj[item.gdlx].yjzczb = Number(
new Decimal(Number(obj[item.gdlx].yjzczb || 0)).plus(
new Decimal(Number(item.yjzczb || 0)),
),
);
obj[item.gdlx].yjzczbj = Number(
new Decimal(Number(obj[item.gdlx].yjzczbj || 0)).plus(
new Decimal(Number(item.yjzczbj || 0)),
),
);
obj[item.gdlx].ycxmzbj = Number(
new Decimal(Number(obj[item.gdlx].ycxmzbj || 0)).plus(
new Decimal(Number(item.ycxmzbj || 0)),
),
);
obj[item.gdlx].yjxmzbj = Number(
new Decimal(Number(obj[item.gdlx].yjxmzbj || 0)).plus(
new Decimal(Number(item.yjxmzbj || 0)),
),
);
} }
obj[item.gdlx].mycgbl = new Decimal(
Number(obj[item.gdlx].mycgbl || 0),
).plus(new Decimal(Number(item.mycgbl || 0)));
obj[item.gdlx].cgbl = new Decimal(Number(obj[item.gdlx].cgbl || 0)).plus(
new Decimal(Number(item.cgbl || 0)),
);
obj[item.gdlx].lrfpbl = new Decimal(
Number(obj[item.gdlx].lrfpbl || 0),
).plus(new Decimal(Number(item.lrfpbl || 0)));
obj[item.gdlx].cze = new Decimal(Number(obj[item.gdlx].cze || 0)).plus(
new Decimal(Number(item.cze || 0)),
);
obj[item.gdlx].yjzczb = new Decimal(
Number(obj[item.gdlx].yjzczb || 0),
).plus(new Decimal(Number(item.yjzczb || 0)));
obj[item.gdlx].ycxmzbj = new Decimal(
Number(obj[item.gdlx].ycxmzbj || 0),
).plus(new Decimal(Number(item.ycxmzbj || 0)));
} }
}); });
jcgdxxSums.value = obj; jcgdxxSums.value = obj;
...@@ -4685,9 +4817,9 @@ const getProjectInfo = () => { ...@@ -4685,9 +4817,9 @@ const getProjectInfo = () => {
pageActiveName.value = "决策信息填报"; pageActiveName.value = "决策信息填报";
} }
// 决策 // 决策
let jcData = res.juece || res.lixiang || {}; let jcData = res.zaijuece || res.lixiang || {};
Object.assign(jcFormData, jcData); Object.assign(jcFormData, jcData);
if (res.juece) { if (res.zaijuece) {
Object.assign(jcSwlzbData, jcData.projectJsgms); Object.assign(jcSwlzbData, jcData.projectJsgms);
Object.assign(dbzqData, jcData.projectZqrzs); Object.assign(dbzqData, jcData.projectZqrzs);
Object.assign(fxglData, jcData.projectFxgls); Object.assign(fxglData, jcData.projectFxgls);
...@@ -4959,7 +5091,7 @@ const saveClick = (type) => { ...@@ -4959,7 +5091,7 @@ const saveClick = (type) => {
url: "/api/project/" + url, url: "/api/project/" + url,
data: params, data: params,
callback: (data) => { callback: (data) => {
router.push("/projectDraft"); router.push("/decision");
}, },
}); });
} else if ( } else if (
...@@ -5070,7 +5202,7 @@ const saveClick = (type) => { ...@@ -5070,7 +5202,7 @@ const saveClick = (type) => {
url: "/api/project/" + url, url: "/api/project/" + url,
data: params, data: params,
callback: (data) => { callback: (data) => {
router.push("/projectArgument"); router.push("/decision");
}, },
}); });
} }
...@@ -5115,11 +5247,6 @@ const navigationItems3 = ref([]); ...@@ -5115,11 +5247,6 @@ const navigationItems3 = ref([]);
const handleNavClick = (item) => { const handleNavClick = (item) => {
console.log("Navigation clicked:", item); console.log("Navigation clicked:", item);
// 点击导航时自动展开对应的折叠面板
if (!activeCollapse.value.includes(item.name)) {
activeCollapse.value.push(item.name);
}
// 等待 DOM 更新后滚动 // 等待 DOM 更新后滚动
nextTick(() => { nextTick(() => {
setTimeout(() => { setTimeout(() => {
......
...@@ -259,7 +259,6 @@ const previewProject = (item) => { ...@@ -259,7 +259,6 @@ const previewProject = (item) => {
name: "xmdakDetaill", name: "xmdakDetaill",
// name: "addProject", // name: "addProject",
query: { query: {
isPreview: true,
projectId: item.id, projectId: item.id,
}, },
}); });
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
</template> </template>
<script setup> <script setup>
import { ref, computed, markRaw } from "vue"; import { ref, computed, markRaw, onMounted } from "vue";
import { useRoute } from "vue-router"; import { useRoute } from "vue-router";
import { import {
Document, Document,
...@@ -66,6 +66,13 @@ import { ...@@ -66,6 +66,13 @@ import {
const route = useRoute(); const route = useRoute();
// 初始化时自动加载第一个tab的第一个子项
onMounted(async () => {
if (projectId.value) {
await switchTab(0);
}
});
// Tab 配置 // Tab 配置
const tabs = ref([ const tabs = ref([
{ {
...@@ -103,13 +110,13 @@ const routeChildren = { ...@@ -103,13 +110,13 @@ const routeChildren = {
name: "projectDraft", name: "projectDraft",
title: "项目遴选", title: "项目遴选",
desc: "项目初选与评估", desc: "项目初选与评估",
importFn: () => import("@/views/projectManage/projectDraft.vue"), importFn: () => import("@/views/projectManage/addProject.vue"),
}, },
{ {
name: "projectSetUp", name: "projectSetUp",
title: "项目立项", title: "项目立项",
desc: "项目立项申请", desc: "项目立项申请",
importFn: () => import("@/views/projectManage/projectSetUp.vue"), importFn: () => import("@/views/projectManage/addProject.vue"),
}, },
{ {
name: "projectArgument", name: "projectArgument",
...@@ -121,12 +128,6 @@ const routeChildren = { ...@@ -121,12 +128,6 @@ const routeChildren = {
name: "projectDecision", name: "projectDecision",
title: "项目决策", title: "项目决策",
desc: "项目投资决策", desc: "项目投资决策",
importFn: () => import("@/views/projectManage/projectDecision.vue"),
},
{
name: "projectAllPage",
title: "项目档案库",
desc: "项目档案管理",
importFn: () => import("@/views/projectManage/addProject.vue"), importFn: () => import("@/views/projectManage/addProject.vue"),
}, },
], ],
...@@ -135,8 +136,7 @@ const routeChildren = { ...@@ -135,8 +136,7 @@ const routeChildren = {
name: "targetLiabilityStatement", name: "targetLiabilityStatement",
title: "投资目标责任书", title: "投资目标责任书",
desc: "投资目标责任管理", desc: "投资目标责任管理",
importFn: () => importFn: () => import("@/views/investingManage/addStatement.vue"),
import("@/views/investingManage/addStatement.vue"),
}, },
{ {
name: "targetControl", name: "targetControl",
...@@ -154,8 +154,7 @@ const routeChildren = { ...@@ -154,8 +154,7 @@ const routeChildren = {
name: "constructionTime", name: "constructionTime",
title: "建设期投资回收", title: "建设期投资回收",
desc: "建设期资金回收", desc: "建设期资金回收",
importFn: () => importFn: () => import("@/views/investingManage/constructionTimeAdd.vue"),
import("@/views/investingManage/constructionTimeAdd.vue"),
}, },
{ {
name: "construction", name: "construction",
...@@ -187,8 +186,7 @@ const routeChildren = { ...@@ -187,8 +186,7 @@ const routeChildren = {
name: "investmentCecovery", name: "investmentCecovery",
title: "运营期投资回收", title: "运营期投资回收",
desc: "运营期收益回收", desc: "运营期收益回收",
importFn: () => importFn: () => import("@/views/castbehind/investmentCecoveryAdd.vue"),
import("@/views/castbehind/investmentCecoveryAdd.vue"),
}, },
{ {
name: "runningPeriod", name: "runningPeriod",
...@@ -218,10 +216,17 @@ const currentTabChildren = computed(() => { ...@@ -218,10 +216,17 @@ const currentTabChildren = computed(() => {
}); });
// 切换 Tab // 切换 Tab
const switchTab = (index) => { const switchTab = async (index) => {
activeTab.value = index; activeTab.value = index;
activeSubItem.value = "";
currentComponent.value = null; // 获取当前Tab的第一个子项
const children = routeChildren[tabs.value[index].key];
if (children && children.length > 0) {
await handleSubItemClick(children[0]);
} else {
activeSubItem.value = "";
currentComponent.value = null;
}
}; };
// 处理子项点击 - 直接加载详情组件 // 处理子项点击 - 直接加载详情组件
...@@ -255,15 +260,22 @@ const handleSubItemClick = async (item) => { ...@@ -255,15 +260,22 @@ const handleSubItemClick = async (item) => {
flex-direction: column; flex-direction: column;
} }
// 主 Tab 切换区域 - 现代政府风格 .detail-section {
.tab-content {
padding: 16px !important;
}
::v-deep .add-project-back {
display: none;
}
}
.main-tab-wrapper { .main-tab-wrapper {
background: white; background: white;
padding: 0; padding: 0;
box-shadow: 0 2px 12px rgba(0, 86, 179, 0.08);
position: sticky; position: sticky;
top: 0; top: 0;
z-index: 100; z-index: 100;
border-bottom: 2px solid #e8f4fd; border-bottom: 1px solid #e8f4fd;
} }
.main-tab-container { .main-tab-container {
...@@ -280,15 +292,14 @@ const handleSubItemClick = async (item) => { ...@@ -280,15 +292,14 @@ const handleSubItemClick = async (item) => {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
padding: 18px 24px; padding: 10px 16px;
cursor: pointer; cursor: pointer;
transition: all 0.3s ease; transition: all 0.3s ease;
position: relative; position: relative;
border-radius: 8px 8px 0 0; margin-top: 0;
margin-top: 4px;
.tab-label { .tab-label {
font-size: 15px; font-size: 14px;
font-weight: 500; font-weight: 500;
color: #5a6c7d; color: #5a6c7d;
letter-spacing: 0.5px; letter-spacing: 0.5px;
...@@ -298,34 +309,31 @@ const handleSubItemClick = async (item) => { ...@@ -298,34 +309,31 @@ const handleSubItemClick = async (item) => {
} }
&::before { &::before {
content: ''; content: "";
position: absolute; position: absolute;
bottom: 0; bottom: 0;
left: 0; left: 0;
right: 0; right: 0;
height: 3px; height: 2px;
background: transparent; background: transparent;
transition: all 0.3s ease; transition: all 0.3s ease;
border-radius: 3px 3px 0 0;
} }
&:hover { &:hover {
background: linear-gradient(to bottom, #f8fbff, #ffffff); background: #f8fbff;
.tab-label { .tab-label {
color: #0056b3; color: #0056b3;
} }
&::before { &::before {
background: linear-gradient(to right, #4dabf7, #0056b3); background: #4dabf7;
opacity: 0.6; opacity: 0.6;
} }
} }
&.active { &.active {
background: white; background: white;
margin-top: 0;
padding-top: 22px;
.tab-label { .tab-label {
color: #0056b3; color: #0056b3;
...@@ -333,23 +341,24 @@ const handleSubItemClick = async (item) => { ...@@ -333,23 +341,24 @@ const handleSubItemClick = async (item) => {
} }
&::before { &::before {
background: linear-gradient(to right, #4dabf7, #0056b3); background: #0056b3;
box-shadow: 0 -2px 8px rgba(0, 86, 179, 0.15);
} }
} }
} }
// 子项导航区域 // 子项导航区域
.sub-tab-wrapper { .sub-tab-wrapper {
background: linear-gradient(to bottom, #f8fbff, #ffffff); background: #ffffff;
border-bottom: 1px solid #d4e8fc; border-bottom: 1px solid #e8f4fd;
padding: 16px 24px; padding: 8px 24px;
box-shadow: 0 2px 8px rgba(0, 86, 179, 0.04); position: sticky;
top: 46px;
z-index: 99;
} }
.sub-tab-container { .sub-tab-container {
display: flex; display: flex;
gap: 12px; gap: 8px;
flex-wrap: wrap; flex-wrap: wrap;
max-width: 1400px; max-width: 1400px;
margin: 0 auto; margin: 0 auto;
...@@ -357,23 +366,28 @@ const handleSubItemClick = async (item) => { ...@@ -357,23 +366,28 @@ const handleSubItemClick = async (item) => {
} }
.sub-tab-item { .sub-tab-item {
padding: 12px 24px; display: flex;
border-radius: 20px; padding: 6px 12px;
border-radius: 4px;
cursor: pointer; cursor: pointer;
transition: all 0.3s ease; transition: all 0.3s ease;
background: white; background: white;
border: 1.5px solid #e8f4fd; border: 1px solid #e8f4fd;
position: relative; position: relative;
overflow: hidden; overflow: hidden;
&::before { &::before {
content: ''; content: "";
position: absolute; position: absolute;
top: 0; top: 0;
left: 0; left: 0;
right: 0; right: 0;
bottom: 0; bottom: 0;
background: linear-gradient(135deg, rgba(77, 171, 247, 0.05), rgba(0, 86, 179, 0.05)); background: linear-gradient(
135deg,
rgba(77, 171, 247, 0.05),
rgba(0, 86, 179, 0.05)
);
opacity: 0; opacity: 0;
transition: opacity 0.3s ease; transition: opacity 0.3s ease;
} }
...@@ -391,7 +405,6 @@ const handleSubItemClick = async (item) => { ...@@ -391,7 +405,6 @@ const handleSubItemClick = async (item) => {
&:hover { &:hover {
border-color: #4dabf7; border-color: #4dabf7;
transform: translateY(-1px); transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(77, 171, 247, 0.15);
&::before { &::before {
opacity: 1; opacity: 1;
...@@ -403,10 +416,9 @@ const handleSubItemClick = async (item) => { ...@@ -403,10 +416,9 @@ const handleSubItemClick = async (item) => {
} }
&.active { &.active {
background: linear-gradient(135deg, #4dabf7, #0056b3); background: #0056b3;
border-color: transparent; border-color: #0056b3;
box-shadow: 0 4px 16px rgba(0, 86, 179, 0.25); transform: translateY(-1px);
transform: translateY(-2px);
&::before { &::before {
background: transparent; background: transparent;
...@@ -415,7 +427,6 @@ const handleSubItemClick = async (item) => { ...@@ -415,7 +427,6 @@ const handleSubItemClick = async (item) => {
.sub-tab-label { .sub-tab-label {
color: white; color: white;
font-weight: 600; font-weight: 600;
text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
} }
} }
} }
...@@ -472,7 +483,7 @@ const handleSubItemClick = async (item) => { ...@@ -472,7 +483,7 @@ const handleSubItemClick = async (item) => {
padding: 12px 16px; padding: 12px 16px;
.tab-label { .tab-label {
font-size: 13px; font-size: 14px;
} }
} }
...@@ -484,7 +495,7 @@ const handleSubItemClick = async (item) => { ...@@ -484,7 +495,7 @@ const handleSubItemClick = async (item) => {
padding: 8px 14px; padding: 8px 14px;
.sub-tab-label { .sub-tab-label {
font-size: 13px; font-size: 14px;
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment