修改项目首页 进行中的项目 以及项目建档相关页面信息

This commit is contained in:
32503
2025-07-11 14:34:26 +08:00
parent 8f4404ff91
commit a1f617cbb9
8 changed files with 165 additions and 62 deletions

View File

@ -46,6 +46,19 @@ export default [
path: '/ProjectLayout/Supplier/HomePageSectionList',
component: './Project/ProjectManage/Supplier/HomePageSectionList',
},
/**
* 项目建档
*/
{
// 项目建档列表
path: '/ProjectLayout/ProjectFiles',
component: './ProjectFiles',
},
{
// 项目建档新增
path: '/ProjectLayout/ProjectFiles/file',
component: './ProjectFiles/file',
},
...bid,
...tender,
...open,

View File

@ -1,7 +1,6 @@
import {
fetchDowntlist, fetchprojectRecords, fetchJuryUpList, fetchJuryDownlist, fetchSupplierUpList, fetchDisposalList, fetchParticipants,
fetchSupplierDownLeftList, fetchSupplierDownRightList, fetchtlist, fetchtlistre, fetchtPageList, fetchtShotList, fetchtClarify,
fetchProjectFileList
fetchSupplierDownLeftList, fetchSupplierDownRightList, fetchtlist, fetchtlistre, fetchtPageList, fetchtShotList, fetchtClarify
} from '../services/dashboard';
import { message } from 'antd';
import { getProId } from '@/utils/session';
@ -198,13 +197,13 @@ export default {
yield put({ type: 'save', payload: { downlist: response.data } })
}
},
*fetchProjectFileList({ payload, callback }, { call, put }) {
const response = yield call(fetchProjectFileList, payload)
console.log(123)
if (response.code == 200) {
yield put({ type: 'save', payload: { projectInProgressList: response.data.records } })
}
},
// *fetchProjectFileList({ payload, callback }, { call, put }) {
// const response = yield call(fetchProjectFileList, payload)
// console.log(123)
// if (response.code == 200) {
// yield put({ type: 'save', payload: { projectInProgressList: response.data.records } })
// }
// },
*fetchprojectRecords({ payload, callback }, { call, put }) {
const response = yield call(fetchprojectRecords, payload)
if (response.code == 200 && response.data.length > 0) {

View File

@ -274,7 +274,11 @@ class manager extends PureComponent {
render: (text, record) => (
<>
<Button type="link" onClick={() => {
sessionStorage.setItem("projectData",JSON.stringify(record))
sessionStorage.setItem("opt","view")
history.push({
pathname: '/ProjectLayout/Manager/HomePageSectionList'
});
}}>项目跟进
</Button>

View File

@ -1,10 +1,11 @@
import React, { useEffect, useRef, useState } from 'react';
import ProTable, { ProColumns, ActionType } from '@ant-design/pro-table';
import { getSectionList } from './service';
import { getSectionList ,getRegisterInfo } from './service';
import { changeDict } from './utils';
import { getDefId, getDicData, getProId, getProMethod } from '@/utils/session';
import { Card } from 'antd';
import {Card, Typography} from 'antd';
import '@/assets/zjl_style.less';
const { Text } = Typography;
import {
getBidOpenTime,
getStartReviewTime,
@ -31,6 +32,15 @@ const HomePageSectionList: React.FC<{}> = () => {
const [isReviewRule, setIsReviewRule] = useState<boolean>(false);
//进度环节有无 true-有 false-无
const [isProcess, setIsProcess] = useState<boolean>(true);
const [data,setData] = useState({
companyName: '',
contactName: '',
contactTelephone: '',
contactFax: '',
contactAddress:'',
contactEmail:'',
fixedLine: ''
});
//资审开标时间有无 true-有 false-无
const [preBidOpen, setPreBidOpen] = useState<any>({
preBidOpenName: '资审开标时间',
@ -48,7 +58,20 @@ const HomePageSectionList: React.FC<{}> = () => {
const [operationSele, setOperationSele] = useState<any>({
sectionName: '采购包跟进',
});
let registerInfo: any = {};
const fetchData = async () =>{
getRegisterInfo(getProId()).then((res: any) => {
console.log(res.data)
registerInfo = res.data
setData(res.data);
});
}
useEffect(() => {
fetchData();
//初始化column字段显示
if (defId == 'bid_prequalification') {
//公开招标(预审+后审)
@ -154,7 +177,7 @@ const HomePageSectionList: React.FC<{}> = () => {
const columns: ProColumns<any>[] = [
{
title: '序号',
title: '序号112233',
render: (_: any, record: any, index: any) => {
return index + 1;
},
@ -238,7 +261,51 @@ const HomePageSectionList: React.FC<{}> = () => {
];
return (
<Card bodyStyle={{ padding: '24px 24px 0px' }} bordered={false}>
<div style={{ padding: 24 }}>
<Card title="报名信息" bordered={false}>
{/* 报名单位名称 - 独占一行 */}
<div style={{ marginBottom: 16, display: 'flex', alignItems: 'center' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text>{data.companyName}</Text>
</div>
{/* 使用Flex布局实现统一对齐 */}
<div style={{ display: 'flex', flexWrap: 'wrap', gap: 32 }}>
{/* 联系人名称和联系人地址 - 优化对齐 */}
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ marginRight: 40, maxWidth: 300 }}>{data.contactName}</Text>
</div>
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ maxWidth: 300 }}>{data.contactAddress}</Text>
</div>
{/* 联系电话和联系人邮箱 - 优化对齐 */}
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ marginRight: 40, maxWidth: 300 }}>{data.contactTelephone}</Text>
</div>
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ maxWidth: 300 }}>{data.contactEmail}</Text>
</div>
{/* 固话和传真 - 优化对齐 */}
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ maxWidth: 300 }}>{data.fixedLine}</Text>
</div>
<div style={{ display: 'flex', alignItems: 'center', marginBottom: 16, flex: '1 1 45%' }}>
<Text type="secondary" style={{ width: '160px', display: 'inline-block' }}></Text>
<Text style={{ maxWidth: 300 }}>{data.contactFax}</Text>
</div>
</div>
</Card>
<Card bodyStyle={{ padding: '24px 24px 0px' }} bordered={false} title={"标段信息"}>
<ProTable
columns={columns}
actionRef={actionRef}
@ -248,43 +315,43 @@ const HomePageSectionList: React.FC<{}> = () => {
//调用分页方法
request={async (params) =>
await getSectionList(getProId()).then(async (response: any) => {
let data = response.data;
let param = {
sectionIds: data.map((ele: any) => ele.id),
};
//获取资审开标时间&开标时间
await getBidOpenTime({ ...param }).then(async (res) => {
if (res.code == 200) {
const openTimeData = res.data;
//获取开始评审时间
await getStartReviewTime({ ...param }).then((resp) => {
if (resp.code == 200) {
data.forEach((e: any) => {
e.preOpenTime =
openTimeData[`${e.id}_1`] == undefined ? '未定' : openTimeData[`${e.id}_1`];
e.openTime =
openTimeData[`${e.id}_2`] == undefined ? '未定' : openTimeData[`${e.id}_2`];
e.time = "未定";
if (resp.data.length == 0) {
} else {
resp.data.forEach((ele: any) => {
if (ele.sectionId == e.id) {
e.time = ele.openTime;
}
});
}
});
}
});
}
});
return {
data: getDataInPage(params.pageSize, params.current, data),
success: response.success,
total: data.length,
pageSize: params.pageSize,
current: params.current,
};
let data = response.data;
let param = {
sectionIds: data.map((ele: any) => ele.id),
};
//获取资审开标时间&开标时间
await getBidOpenTime({ ...param }).then(async (res) => {
if (res.code == 200) {
const openTimeData = res.data;
//获取开始评审时间
await getStartReviewTime({ ...param }).then((resp) => {
if (resp.code == 200) {
data.forEach((e: any) => {
e.preOpenTime =
openTimeData[`${e.id}_1`] == undefined ? '未定' : openTimeData[`${e.id}_1`];
e.openTime =
openTimeData[`${e.id}_2`] == undefined ? '未定' : openTimeData[`${e.id}_2`];
e.time = "未定";
if (resp.data.length == 0) {
} else {
resp.data.forEach((ele: any) => {
if (ele.sectionId == e.id) {
e.time = ele.openTime;
}
});
}
});
}
});
}
});
return {
data: getDataInPage(params.pageSize, params.current, data),
success: response.success,
total: data.length,
pageSize: params.pageSize,
current: params.current,
};
})
}
rowKey="id"
@ -295,6 +362,7 @@ const HomePageSectionList: React.FC<{}> = () => {
dateFormatter="string"
/>
</Card>
</div>
);
};

View File

@ -28,3 +28,15 @@ export async function getSectionList(params: any) {
method: 'GET',
});
}
/**
* 查询标段列表
* @method POST
*/
export async function getRegisterInfo(params: any) {
return request('/api/biz-service-ebtp-tender/v1/supplier_register/packages/supplied/getSupplierRegisterInfo/' + params, {
method: 'GET',
});
}

View File

@ -95,7 +95,7 @@ const ProjectFiles: React.FC = () => {
{(
<Button type="link" onClick={() =>
history.push({
pathname: '/ProjectFiles/file',
pathname: '/ProjectLayout/ProjectFiles/file',
state: {
record: record,
opt: 'view',
@ -108,7 +108,7 @@ const ProjectFiles: React.FC = () => {
{(record.status=== 4) &&(
<Button type="link" onClick={() =>
history.push({
pathname: '/ProjectFiles/file',
pathname: '/ProjectLayout/ProjectFiles/file',
state: {
record: record,
opt: 'edit'
@ -120,7 +120,7 @@ const ProjectFiles: React.FC = () => {
{(record.status=== 1) && (
<Button type="link" onClick={() => {
history.push({
pathname: '/ProjectFiles/file',
pathname: '/ProjectLayout/ProjectFiles/file',
state: {
record: record,
opt: 'assign',

View File

@ -14,7 +14,7 @@ import ProForm, {
} from '@ant-design/pro-form';
import { PageContainer, FooterToolbar } from '@ant-design/pro-layout';
import {
dispatch, initProjectEntrustForCosco,
dispatch, getProjectOne, initProjectEntrustForCosco,
updateProjectEntrust
} from './service';
import styles from './style.less';
@ -184,9 +184,10 @@ const ProjectFileCreate: React.FC<Record<string, any>> = () => {
const formRef = useRef<FormInstance>();
const [form] = Form.useForm();
const location = useLocation();
const recordInfo = location?.state?.record;
const projectData: any | null = sessionStorage.getItem('projectData');
const recordInfo = location?.state?.record?location?.state?.record: projectData?JSON.parse(projectData): undefined;
const myRoleCode = location?.state?.myRoleCode;
const opt = location?.state?.opt;
const opt = location?.state?.opt? location?.state?.opt:sessionStorage.getItem("opt")?sessionStorage.getItem("opt"):null;
const isAgencyAdmin = myRoleCode === 'ebtp-agency-admin' || false;//是否是代理机构管理员
const isDrafts = recordInfo?.status === 4;//ProjectEntrust表中 status 4 代表 草稿
const isEntrustProject = recordInfo?.organization === 'organization_1';
@ -239,11 +240,11 @@ const ProjectFileCreate: React.FC<Record<string, any>> = () => {
regionDict = regionDictId
}
if(recordInfo.bidOrgDict === 'organization_2'){
if(recordInfo.openTenderForm === 'open_tender_form_1'){
recordInfo.openTenderForm = '001'
}else if(recordInfo.openTenderForm === 'open_tender_form_2'){
recordInfo.openTenderForm = '002'
}
// if(recordInfo.openTenderForm === 'open_tender_form_1'){
// recordInfo.openTenderForm = '001'
// }else if(recordInfo.openTenderForm === 'open_tender_form_2'){
// recordInfo.openTenderForm = '002'
// }
recordInfo.openTenderForm = openTenderFormMap.get(recordInfo.openTenderForm);
//委托代理项目表中 跟 项目建档 表字段数据统一
recordInfo.procurementMode = recordInfo.bidMethodDict ;
@ -265,6 +266,10 @@ const ProjectFileCreate: React.FC<Record<string, any>> = () => {
}
}, [formRef, recordInfo, opt])
// useEffect( () => {
// },[projectId,opt]);
const [error, setError] = useState<ErrorField[]>([]);
const getErrorInfo = (errors: ErrorField[]) => {
const errorCount = errors.filter((item) => item.errors.length > 0).length;

View File

@ -291,6 +291,8 @@ const ProjectFiles: React.FC = () => {
type="primary"
key="primary"
onClick={() => {
sessionStorage.removeItem("projectData");
sessionStorage.removeItem("opt")
history.push('/ProjectFiles/file?action=create');
}}
>