明树Git Lab

Commit d57c83ce authored by yangyajing's avatar yangyajing

投资目标责任书

parent c7b422a8
Pipeline #105876 passed with stage
in 16 seconds
...@@ -46,15 +46,6 @@ const { proxy } = getCurrentInstance(); ...@@ -46,15 +46,6 @@ const { proxy } = getCurrentInstance();
const router = useRouter(); const router = useRouter();
// 计算菜单路由
const menuRoutes = computed(() => {
const mainRoute = router.options.routes.find((route) => route.path === "/");
if (!mainRoute?.children) return [];
return mainRoute.children.filter(
(route) => !route.meta || route.meta.showInMenu !== false
);
});
// 获取资源库数据 // 获取资源库数据
const getResourceData = () => { const getResourceData = () => {
proxy.$post({ proxy.$post({
......
<template>
<div class="breadcrumb">
<el-breadcrumb separator="/">
<el-breadcrumb-item>
<router-link to="/homePage">首页</router-link>
</el-breadcrumb-item>
<el-breadcrumb-item v-for="item in breadcrumbList" :key="item.path">
<router-link :to="item.path">{{ item.title }}</router-link>
</el-breadcrumb-item>
</el-breadcrumb>
</div>
</template>
<script setup>
import { ref, watch } from 'vue'
import { useRoute } from 'vue-router'
const route = useRoute()
const breadcrumbList = ref([])
// 生成面包屑数据
const generateBreadcrumb = matchedRoutes => {
return matchedRoutes
.filter(route => route.meta?.menuName && route.path !== '/homePage')
.map(route => ({
path: route.path,
title: route.meta?.menuName || route.name || '未知页面'
}))
}
watch(
() => route.matched,
newVal => {
breadcrumbList.value = generateBreadcrumb(newVal)
},
{ immediate: true }
)
</script>
<style scoped lang="less">
.breadcrumb {
margin-bottom: 16px;
padding: 8px 0;
border-radius: 4px;
}
</style>
import { createRouter, createWebHashHistory } from 'vue-router' import { createRouter, createWebHashHistory } from 'vue-router'
import MainLayout from '@/layouts/MainLayout.vue'
import { useUserStore } from "@/stores/user.js"; import { useUserStore } from "@/stores/user.js";
import { routes } from "./routes.js"
const routes = [
{
path: '/login',
name: 'login',
component: () => import('@/views/login/index.vue'),
meta: { nopermission: true }
},
{
path: '/gzbPage',
name: 'gzbPage',
title: '数据大屏',
component: () => import('@/views/homePage/index.vue'),
meta: { menuName: '数据大屏', icon: 'platform', nopermission: true }
},
{
path: '/',
name: '首页',
redirect: '/homePage',
component: MainLayout,
children: [
{
path: '/homePage',
name: 'dataSummary',
title: '数据大屏',
component: () => import('@/views/homePage/index.vue'),
meta: { menuName: '数据大屏', icon: 'platform' }
},
{
path: '/projectManage',
name: 'projectManage',
title: '项目管理',
meta: { menuName: '项目管理', icon: 'Management' },
redirect: "/projectAllPage",
children: [
{
path: '/projectDraft',
name: 'projectDraft',
title: '项目遴选',
component: () => import('@/views/managePage/projectDraft.vue'),
meta: { menuName: '项目遴选' }
},
{
path: '/projectSetUp',
name: 'projectSetUp',
title: '项目立项',
component: () => import('@/views/managePage/projectSetUp.vue'),
meta: {
menuName: '项目立项'
}
},
{
path: '/projectArgument',
name: 'projectArgument',
title: '项目论证',
component: () => import('@/views/managePage/projectArgument.vue'),
meta: {
menuName: '项目论证'
}
},
{
path: '/projectDecision',
name: 'projectDecision',
title: '项目决策',
component: () => import('@/views/managePage/projectDecision.vue'),
meta: {
menuName: '项目决策'
}
},
{
path: '/projectAllPage',
name: 'projectAllPage',
title: '项目档案库',
component: () => import('@/views/managePage/projectAllPage.vue'),
meta: { menuName: '项目档案库' }
},
{
path: '/addProject/:type',
name: 'addProject',
title: '新增项目',
component: () => import('@/views/managePage/addProject.vue'),
meta: {
menuName: '新增项目',
showInMenu: false // 不在菜单中显示
}
}
]
},
{
path: '/templateManage',
name: 'templateManage',
title: '模板管理',
component: () => import('@/views/managePage/templateManage.vue'),
meta: { menuName: '模板管理', icon: 'Management' }
},
{
path: '/systemManage',
name: '系统管理',
title: 'systemManage',
meta: { menuName: '系统管理', icon: 'tools' },
children: [
{
path: '/systemManage/departManage',
name: '部门管理',
title: 'departManage',
component: () => import('@/views/systemManage/departManage.vue'),
meta: { menuName: '部门管理',}
},
{
path: '/systemManage/userManage',
name: '用户管理',
title: 'userManage',
component: () => import('@/views/systemManage/userManage.vue'),
meta: { menuName: '用户管理',}
},
{
path: '/systemManage/roleManage',
name: '角色管理',
title: 'roleManage',
component: () => import('@/views/systemManage/roleManage.vue'),
meta: { menuName: '角色管理',}
},
{
path: '/systemManage/menuManage',
name: '菜单管理',
title: 'menuManage',
component: () => import('@/views/systemManage/menuManage.vue'),
meta: { menuName: '菜单管理',}
}
]
},
{
path: "/building",
name: "building",
title: "建设中",
component: () => import("@/views/homePage/building.vue")
}
]
}
]
const router = createRouter({ const router = createRouter({
history: createWebHashHistory(), history: createWebHashHistory(),
routes routes
......
import MainLayout from '@/layouts/MainLayout.vue'
const routes = [
{
path: '/login',
name: 'login',
component: () => import('@/views/login/index.vue'),
meta: { nopermission: true }
},
{
path: '/gzbPage',
name: 'gzbPage',
title: '数据大屏',
component: () => import('@/views/homePage/index.vue'),
meta: { nopermission: true }
},
{
path: '/',
name: '首页',
redirect: '/homePage',
component: MainLayout,
children: [
{
path: '/homePage',
name: 'dataSummary',
title: '数据大屏',
component: () => import('@/views/homePage/index.vue')
},
{
path: '/projectManage',
name: 'projectManage',
title: '投前管理',
redirect: "/projectAllPage",
children: [
{
path: '/projectDraft',
name: 'projectDraft',
title: '项目遴选',
component: () => import('@/views/managePage/projectDraft.vue')
},
{
path: '/projectSetUp',
name: 'projectSetUp',
title: '项目立项',
component: () => import('@/views/managePage/projectSetUp.vue')
},
{
path: '/projectArgument',
name: 'projectArgument',
title: '项目论证',
component: () => import('@/views/managePage/projectArgument.vue')
},
{
path: '/projectDecision',
name: 'projectDecision',
title: '项目决策',
component: () => import('@/views/managePage/projectDecision.vue')
},
{
path: '/projectAllPage',
name: 'projectAllPage',
title: '项目档案库',
component: () => import('@/views/managePage/projectAllPage.vue')
},
{
path: '/addProject/:type',
name: 'addProject',
title: '新增项目',
component: () => import('@/views/managePage/addProject.vue')
}
]
},
{
path: "/investingManage",
name: "investingManage",
title: "投中管理",
redirect: "/targetLiabilityStatement",
children: [
{
path: "/targetLiabilityStatement",
name: "targetLiabilityStatement",
title: "投资目标责任书",
component: () => import('@/views/investingManage/targetLiabilityStatement.vue')
},
{
path: '/addStatement',
name: 'addStatement',
title: '新增责任书',
component: () => import('@/views/investingManage/addStatement.vue')
}
]
},
{
path: '/templateManage',
name: 'templateManage',
title: '模板管理',
component: () => import('@/views/managePage/templateManage.vue')
},
{
path: '/systemManage',
name: '系统管理',
title: 'systemManage',
meta: { menuName: '系统管理' },
children: [
{
path: 'departManage',
name: '部门管理',
title: 'departManage',
component: () => import('@/views/systemManage/departManage.vue')
},
{
path: 'userManage',
name: '用户管理',
title: 'userManage',
component: () => import('@/views/systemManage/userManage.vue')
},
{
path: 'roleManage',
name: '角色管理',
title: 'roleManage',
component: () => import('@/views/systemManage/roleManage.vue')
},
{
path: 'menuManage',
name: '菜单管理',
title: 'menuManage',
component: () => import('@/views/systemManage/menuManage.vue')
}
]
},
{
path: "/building",
name: "building",
title: "建设中",
component: () => import("@/views/homePage/building.vue")
}
]
}
];
export {
routes
};
\ No newline at end of file
...@@ -86,4 +86,115 @@ ...@@ -86,4 +86,115 @@
} }
} }
} }
}
.add-project{
&-container{
width: 100%;
height: 100%;
padding: 20px;
box-sizing: border-box;
display: flex;
flex-direction: column;
.el-collapse-item__header{
color: var(--el-color-primary);
}
}
&-header{
display: flex;
justify-content: space-between;
}
&-content{
flex: 1;
height: 0;
display: flex;
flex-direction: column;
.tabs-content{
flex: 1;
max-height: 100%;
}
.el-tabs{
height: 100%;
}
.el-tab-pane{
height: 100%;
.tab-content{
height: 100%;
overflow: auto;
padding: 0 20px;
.col-title{
height: 24px;
line-height: 24px;
font-weight: bold;
text-align: center;
}
.tab-handle{
margin: 10px 0;
display: flex;
justify-content: flex-end;
}
.el-table{
margin-bottom: 10px;
thead {
color: #000;
th{
background: #f5f7fa;
.cell{
text-align: center;
}
}
}
.sums-column{
display: flex;
flex-direction: column;
justify-content: flex-start;
&>div{
height: 26px;
line-height: 26px;
text-align: center;
}
}
}
.upload-file-wrap{
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.file-name{
flex: 1;
width: 0;
color: #409eff;
cursor: pointer;
-webkit-background-clip: text;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.delete-btn{
cursor: pointer;
color: #F56C6C;
}
}
.el-select__wrapper{
.el-select__selection.is-near{
max-height: 120px;
overflow: auto;
}
}
}
.always-click{
padding: 2px;
font-size: 12px;
cursor: pointer !important;
color: var(--el-color-primary);
font-weight: 500;
font-family: Arial, sans-serif;
display: inline-flex;
align-items: center;
}
}
.project-tab-content{
padding: 0 20px;
height: 100%;
}
}
} }
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<template>
<div class="project-manage-container">
<div class="manage-container">
<div class="project-manage-header">
<div class="header-left"></div>
<div class="header-right">
<el-button type="primary" @click="addStatement">新增</el-button>
</div>
</div>
<div class="project-manage-content" v-loading="loading">
<common-table
:autoHeight="true"
:maxRows="10"
:data="tableData"
:columns="tableColumns"
:total="total"
:current-page="currentPage"
:page-size="pageSize"
:index="true"
:indexLabel="'序号'"
title=""
:border="true"
@size-change="handleSizeChange"
@current-page-change="handleCurrentPageChange"
>
<template #operations="{ row, index }">
<el-button link type="primary" size="small" @click="previewStatement(row)">查看</el-button>
<el-button link type="primary" size="small" @click="editStatement(row)">编辑</el-button>
</template>
</common-table>
</div>
</div>
</div>
</template>
<script setup>
import { ref, onMounted, getCurrentInstance } from "vue";
import { useRouter } from "vue-router";
import CommonTable from "@/components/common/commonTable.vue";
const router = useRouter();
const { proxy } = getCurrentInstance();
let tableData = ref([]);
let tableColumns = ref([
{
prop: "projectName",
label: "项目名称",
showOverflowTooltip: true
},
{
prop: "projectCode",
label: "项目编号",
showOverflowTooltip: true
},
{
prop: "operations",
label: "操作",
width: 170,
slot: "operations",
fixed: "right",
align: "center"
}
]);
let loading = ref(false);
let total = ref(0);
let currentPage = ref(1);
let pageSize = ref(10);
// 获取列表数据
const getStatementData = () => {
loading.value = true;
proxy.$post({
url: "/api/project/getTzmbzrsList",
data: {
page: currentPage.value,
pagesize: pageSize.value
},
callback: (data) => {
tableData.value = data.rows;
total.value = data.count;
loading.value = false;
}
})
};
// 分页
const handleSizeChange = (size) => {
pageSize.value = size;
currentPage.value = 1;
getStatementData();
}
const handleCurrentPageChange = (page) => {
currentPage.value = page;
getStatementData();
}
const addStatement = () => {
router.push("/addStatement");
};
const editStatement = (item) => {
router.push({
name: "addStatement",
query: {
projectId: item.id
}
});
};
const previewStatement = (item) => {
router.push({
name: "addStatement",
query: {
isPreview: true,
projectId: item.id
}
})
}
onMounted(() => {
getStatementData();
})
</script>
<style scoped lang="less">
@import "@/styles/manage.less";
</style>
\ No newline at end of file
This diff is collapsed.
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