修改项目首页 进行中的项目 以及项目建档相关页面信息
This commit is contained in:
@ -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>
|
||||
);
|
||||
};
|
||||
|
||||
|
@ -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',
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user