3.10 工程代码同步master

This commit is contained in:
jl-zhoujl2
2022-03-10 14:24:13 +08:00
parent 41ab55a4ac
commit 62f6b07ee2
914 changed files with 143121 additions and 29110 deletions

View File

@ -0,0 +1,19 @@
import React, { useEffect,useState } from 'react';
import {} from '@/utils/CommonUtils'
const BidOpeningFormModal: React.FC<{}> = () =>{
useEffect(() => {
window.open("../bidOpening/bidOpening.html?roomType=2");
},[])
return (
<>
</>
//<div dangerouslySetInnerHTML={{ __html: '<!DOCTYPE html><html lang="en"><script type="text/javascript"src="../jquery.js"></script><head><meta charset="UTF-8"><title>开标大厅-招标采购中心</title><link href="css/bidOpening.css"rel="stylesheet"type="text/css"></head><body><!--内容区--><div><!--红头--><div class="headerArea"><img src="images/logo.svg"alt=""width="30"class="headerPic"/><h2>中国联通智慧供应链平台|招标采购中心</h2></div><!--<!--开标大厅--><div class="openMeeting"><!--上部--><div class="meetingTop"><!--当前时间--><div class="bidLeft"><p>当前时间:</p><p id="dateTime"><span></span>/<span></span>/<span></span><span></span>:<span></span>:<span></span></p></div><!--<div class="tableBlock"><table class="bidOpeningTable"cellpadding="0"cellspacing="0"><thead><tr><th width="10%">序号</th><th width="20%">标段名称</th><th width="15%">标段编号</th><th width="15%">开标时间</th><th width="10%">开标状态</th><th width="*">操作</th></tr></thead><tbody id="dataDev"><tr style="height: 0px;"><th width="10%"></th><th width="21%"></th><th width="15%"></th><th width="15%"></th><th width="10%"></th><th width="*"></th></tr></tbody></table></div></div><!--<!--下部--><div class="meetingBottom"><img src="images/elementPic.png"alt=""/></div><!--</div><!--</div><!--<script>var tpId="1111111";$.ajax({url:"http://10.242.31.158:8100/biz-service-ebtp-opening/v1/bizbidopenroom/openRoomList/"+tpId,data:{pageNo:"1",pageSize:"100",roomType:"2"},type:"GET",success:function(re){var list=re.data.records;var tr="";for(var i=0;i<list.length;i++){tr=tr+"<tr>";tr=tr+"<td>"+(i+1)+"</td>";tr=tr+"<td>"+(list[i].sectionName)+"</td>";tr=tr+"<td>"+(list[i].sectionNo)+"</td>";tr=tr+"<td>"+(list[i].opingTime)+"</td>";tr=tr+"<td>"+(getRoomStateValue(list[i].roomState))+"</td>";tr=tr+"<td>";if(list[i].roomState>0){tr=tr+"<button type="button" onClick=onClickToOpenRoom("+list[i].id+","+list[i].turnSort+","+list[i].roomType+","+list[i].roomState+") class="bidBtn01">在线唱标</button>"}tr=tr+"<button type="button" onClick=onClickDown("+list[i].sectionId+") class="bidBtn02">导出投标记录</button></td>";tr=tr+"</tr>"}$("#dataDev").html("");$("#dataDev").append("<tr style="height: 0px;" id="dataTr"></tr>");$("#dataTr").append("<th width="10%"></th>").append("<th width="21%"></th>").append("<th width="15%"></th>").append("<th width="15%"></th>").append("<th width="10%"></th>").append("<th width="*"></th>");$("#dataDev").append(tr)}});function getRoomStateValue(state){var value="";if(state=="0"){value="未开标"}if(state=="1"){value="开标"}if(state=="2"){value="唱标"}if(state=="3"){value="唱标结束"}if(state=="4"){value="取消开标"}return value}function time(){var date=new Date();var n=date.getFullYear();var y=date.getMonth()+1;y=y<10?"0"+y:y;var t=date.getDate();t=t<10?"0"+t:t;var h=date.getHours();h=h<10?"0"+h:h;var m=date.getMinutes();m=m<10?"0"+m:m;var s=date.getSeconds();s=s<10?"0"+s:s;$("#dateTime span").eq(0).html(n);$("#dateTime span").eq(1).html(y);$("#dateTime span").eq(2).html(t);$("#dateTime span").eq(3).html(h);$("#dateTime span").eq(4).html(m);$("#dateTime span").eq(5).html(s);for(var i=0;i<$("#dateTime").length;i++){if($("div").eq(i).text().length==1){$("div").eq(i).html(function(index,html){return 0+html})}}}time();setInterval(time,1000);function onClickToOpenRoom(aa,bb,roomType,roomState){if(roomState>0){window.open("http://10.242.31.158:18022/room/index?aa="+aa+"&bb="+bb+"&roomType="+roomType)}}function onClickDown(bsId){window.open("http://10.242.31.158:8100/biz-service-ebtp-opening/v1/bizbidopenroom/exportTenderRecords/"+bsId)}</script></body></html>' }} />
);
};
export default BidOpeningFormModal;

View File

@ -1,14 +1,20 @@
import React, { useRef, useState, } from 'react';
import { Tabs, Divider, PageHeader, Spin, Card, message, Popconfirm } from 'antd';
import React, { useEffect, useRef, useState, } from 'react';
import { Spin, message, Popconfirm, Button, Modal } from 'antd';
import ProTable, { ActionType, ProColumns } from '@ant-design/pro-table';
import Xuni from '../../../../images/Xuni/xuni.jpg';
import { updateState, getList, } from './service';
import { getProId, getSessionUserData } from '@/utils/session';
import { updateState, getList, getListGys, getMan } from './service';
import { getProId, getSessionRoleData, getProMethod } from '@/utils/session';
import FileDown from '@/utils/Download';
import { getURLInformation } from '@/utils/CommonUtils'
import '@/assets/xsy_style.less'
import { ExclamationCircleOutlined } from '@ant-design/icons';
import { btnAuthority } from '@/utils/authority';
//开标
const open = async (fields: any) => {
const hide = message.loading('正在开启');
try {
const success = await updateState({ ...fields });
const success = await updateState({ ...fields }).then((res) => {
return res.success
});
hide();
if (success) {
message.success('开启成功');
@ -26,7 +32,9 @@ const open = async (fields: any) => {
const cancel = async (fields: any) => {
const hide = message.loading('正在取消');
try {
const success = await updateState({ ...fields });
const success = await updateState({ ...fields }).then((res) => {
return res.success
});
hide();
if (success) {
message.success('取消成功');
@ -42,10 +50,65 @@ const cancel = async (fields: any) => {
};
const Sing: React.FC<{}> = () => {
const { TabPane } = Tabs;
const roomType = getURLInformation('roomType');
//控制字段 角色、开标状态、唱标阶段、是否需要ipass解密
const juese = getSessionUserData().roleIds//daili 代理 gys 供应商
const juese = getSessionRoleData().roleCode//ebtp-agency-project-manager 代理 ebtp-supplier 供应商
const [data, dataSet] = useState<any>([]);
const [count, countSet] = useState<any>(0);
const [pageData, pageDataSet] = useState<any>({
pageNo: 1,
pageSize: 10,
});
const method = getProMethod();//项目类型字典项
const { confirm } = Modal;
let showNameT: any = { tbr: '', bd: '', kb: '' }//投标人供应商
if (method === 'procurement_mode_1' || method === 'procurement_mode_2') {//招标
showNameT = { tbr: '投标人', bd: '标段', kb: '开标' };
} else {
showNameT = { tbr: '供应商', bd: '采购包', kb: '开启' }
}
useEffect(() => {
if (juese === 'ebtp-supplier') {
getDataGys();
}else {
getData();
}
setTimeout(() => {
countSet(count + 1)
}, 2000);
}, [count, pageData])
async function getData() {//代理获取列表
await getList({ projectId: getProId(), ...pageData, roomType: roomType }).then((res) => {
if (res?.code == 200) {
dataSet(res.data);
}
})
}
async function getDataGys() {//供应商获取列表
await getListGys({ projectId: getProId(), ...pageData, roomType: roomType }).then((res) => {
if (res?.code == 200) {
dataSet(res.data);
}
})
}
async function showConfirm(record: any) {//环节流转提示
confirm({
title: `${showNameT.tbr}不足三家是否开启?`,
icon: <ExclamationCircleOutlined />,
centered: true,
okText: '确定',
cancelText: '取消',
onOk() {
openRoom(record);
},
onCancel() {
actionRef.current?.reload();
setSpin(false);
}
});
}
//Spin
const [spin, setSpin] = useState<boolean>(false);
const actionRef = useRef<ActionType>();
@ -53,138 +116,129 @@ const Sing: React.FC<{}> = () => {
//标段列表表格
const columns: ProColumns<any>[] = [
{ title: '序号', dataIndex: 'index', valueType: 'index', width: 50, },
{ title: '标段名称', dataIndex: 'sectionName', },
{ title: '标段编号', dataIndex: 'sectionNo', },
{ title: '开标时间', dataIndex: 'opingTime', width: 150, valueType: 'dateTime' },
{ title: `${showNameT.bd}名称`, dataIndex: 'sectionName', },
{ title: `${showNameT.bd}编号`, dataIndex: 'sectionNo', },
{ title: `${showNameT.kb}时间`, dataIndex: 'opingTime', valueType: 'dateTime' },
{
title: '开标状态', dataIndex: 'roomState', width: 90,
title: '开标状态', dataIndex: 'roomState',
valueEnum: {
0: { text: '未开标', status: 'Warning' },
1: { text: '已开标', status: 'Processing' },
2: { text: '唱标中', status: 'Processing' },
3: { text: '唱标结束', status: 'success' },
4: { text: '已取消', status: 'Error' },
0: { text: '未开标', },
1: { text: '已开标', },
2: { text: '唱标中', },
3: { text: '唱标结束', },
4: { text: '已取消', },
9: { text: '异常处理', },
}
},
{
title: '操作', valueType: 'option', width: 270,
render: (_, record) => {
const endTime = new Date(record.docEndTime?.replace(/-/g,'/'))
const currentTime = new Date(record.systemDate?.replace(/-/g,'/'))
return (
<>
{record.roomState == 0 && juese === 'daili' ? <>
<a onClick={async () => {
const a = new Date(record.opingTime);
const b = new Date();
if (a > b) {
message.error("开标时间未到!");
} else if (a < b || a == b) {
{
record.roomState == 0 ?
<Button hidden={btnAuthority(['ebtp-agency-project-manager', 'ebtp-purchase'])} type='text' onClick={async () => {
setSpin(true);
//到时间了
const success = await open({ id: record.id, roomState: 1 ,projectId:record.projectId,sectionId:record.sectionId});
if (success) {
window.open(`/room/index?aa=${record.assessRoomId}&bb=${record.turnSort}`);
let gysCount = 0;
await getMan(record.turnId).then((res) => {
if (res?.code == 200) {
gysCount = res.data?.length;
}
})
if (method === 'procurement_mode_3' && gysCount == 2) {//公开必选 2家 提示 是否继续开标
showConfirm(record);
} else {
openRoom(record);
}
actionRef.current?.reload();
setSpin(false);
}
}}></a>
<Divider type="vertical" />
</> : null}
{(record.roomState == 1 || record.roomState == 2 || record.roomState == 3) && juese === 'daili' ? <>
<a onClick={() => {
window.open(`/room/index?aa=${record.assessRoomId}&bb=${record.turnSort}`)
}}></a>
<Divider type="vertical" />
</> : null}
{juese === 'daili' && record.roomState != 3 && record.roomState != 4 ? <>
<Popconfirm
placement="topRight"
title={"确定取消开标么?"}
onConfirm={() => { setSpin(true); confirm(record.id); }}
okText="确定"
cancelText="取消"
>
<a></a>
</Popconfirm>
<Divider type="vertical" />
</> : null}
{juese === 'daili' ? <>
<a onClick={() => { console.log(); }}></a>
</> : null}
{juese === 'gys' ? <>
<a onClick={async() => {
const a = new Date(record.opingTime);
const b = new Date();
if (a > b) {
message.error("开标时间未到!");
} else if (a < b || a == b) {
//到时间了
window.open(`/room/index?aa=${record.assessRoomId}&bb=${record.turnSort}`);
actionRef.current?.reload();
setSpin(false);
}
}}></a>
</> : null}
}}></Button> : null
}
{
(record.roomState == 1 || record.roomState == 2 || record.roomState == 3) ?
<Button type='text' onClick={() => {
window.open(`/room/index?aa=${record.assessRoomId}&bb=${record.turnSort}&roomType=${roomType}`)
}}>
</Button> : null
}
{
record.roomState != 3 && record.roomState != 4 && record.roomState != 9 ?
<Popconfirm
placement="topRight"
title={"确定取消开标么?"}
onConfirm={() => {
setSpin(true);
confirmCancel(record.id);
}}
okText="确定"
cancelText="取消"
>
<Button hidden={btnAuthority(['ebtp-agency-project-manager', 'ebtp-purchase'])} type='text' ></Button>
</Popconfirm> : null
}
{
(juese === 'ebtp-agency-project-manager' || juese === 'ebtp-purchase') && (currentTime > endTime) ?
<FileDown
apiUrl={`/api/biz-service-ebtp-opening/v1/bizbidopenroom/exportTenderRecords/${record.sectionId}?roomType=${roomType}`}
method='GET'
fileName={`${record.projectName}-${record.sectionName}-投递记录`}
type='xlsx'
btnName='导出投递记录'
tag='a'
/> : null
}
</>
)
}
},
];
const confirm = async (roomId: any) => {
//取消开标
const confirmCancel = async (roomId: any) => {
const success = await cancel({ id: roomId, roomState: 4 });
success ? actionRef.current?.reload() : null;
setSpin(false);
};
//控制展示页
const callback = (key: any) => { }
//开标
async function openRoom(record: any) {
const success = await open({ id: record.id, roomState: 1, projectId: record.projectId, sectionId: record.sectionId });
if (success) {
window.open(`/room/index?aa=${record.assessRoomId}&bb=${record.turnSort}&roomType=${roomType}`);
}
actionRef.current?.reload();
setSpin(false);
}
//时间
// const [date, dateSet] = useState<any>();
// function getDate(idContent: any) {
// var date = new Date()
// var date1 = date.toLocaleString();
// var div1 = document.getElementById(idContent);
// if (div1 != null) {
// dateSet(date1);
// }
// }
// setInterval(() => getDate('currentTime'), 1000)
return (
<>
<PageHeader title="开标列表" style={{ backgroundColor: "white", borderBottom: "solid", borderBottomColor: 'rgb(239,242,245)', borderWidth: '1px', borderRadius: "10px", }} />
<Spin spinning={spin}>
<Tabs onChange={callback} type='card' size="large" style={{ backgroundColor: '#fff' }}>
<TabPane tab="标段列表" key="1">
<Card bordered={false}>
{/* <div id="currentTime">{date}</div> */}
<ProTable
columns={columns}//表格
actionRef={actionRef}
search={false}
rowSelection={false}
options={false}
pagination={{ defaultPageSize: 10 }}
request={() => getList({ projectId: getProId() }).then((res) => {
console.log(res);
const result = {
data: res.data,
total: res.data.total,
success: res.data.success,
pageSize: res.data.pageSize,
current: res.data.current
};
return result;
})}
/>
</Card>
</TabPane>
<TabPane tab="虚拟大厅" key="2">
<img src={Xuni} alt="" width='100%' height={700} />
</TabPane>
</Tabs>
</Spin>
</>
<Spin spinning={spin}>
<div className='xsy-headerDiv pd24'>
<h3 className="first-title floatLeft">{showNameT.kb}</h3>
<div className='xsy-rightDiv-struct'>
<Button type="primary" onClick={() => window.open(`../bidOpening/bidOpening.html?&roomType=${roomType}`)}></Button>
</div>
</div>
<ProTable
columns={columns}//表格
actionRef={actionRef}
search={false}
rowSelection={false}
options={false}
pagination={{
defaultPageSize: 10,
onChange: (page, pageSize) => pageDataSet({ pageNo: page, pageSize: pageSize }),
total: data.total,
pageSize: pageData.pageSize,
current: pageData.pageNo,
onShowSizeChange: (current, size) => pageDataSet({ pageNo: current, pageSize: size }),
}}
dataSource={data.records}
style={{ marginTop: '16px', padding: '0px 24px' }}
/>
</Spin>
)
}
export default Sing;
export default Sing;

View File

@ -2,7 +2,15 @@ import request from '@/utils/request';
//获取列表
export async function getList(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidopenroom/openRoomList/${params.projectId}`);
return request(`/api/biz-service-ebtp-opening/v1/bizbidopenroom/openRoomList/${params.projectId}`,{
params:params
});
}
//获取列表gys
export async function getListGys(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidopenroom/payerOpenRoomList/${params.projectId}`,{
params:params
});
}
//获取北京时间
export async function getTime() {
@ -16,4 +24,8 @@ export async function updateState(params?: any) {
...params
}
});
}
//获取报名人数
export async function getMan(reviewTurnId?: any) {
return request(`/api/biz-service-ebtp-tender/v1/supplier_register/get_register/${reviewTurnId}`);
}

View File

@ -0,0 +1,229 @@
@import '~antd/lib/style/themes/default.less';
@media screen and (max-width: 1980px) {
.backgroundt{
width:1598px;
height: 999px;
// background-size: 100% 100%;
background: url(./../../../../images/opening/vroom.png) center center;
overflow: auto;
.date{
width: 7%;
margin-left: 15%;
// padding-top: 15%;
padding-top: 255px;
font-size: 20px;
float: left;
color: #FFFFFF;
}
.table{
margin:auto 0;
width: 43.5%;
height: 270px;
margin-left: 7%;
// font-size: 17px;
color:#FFFFFF;
// padding-top: 13%;
padding-top: 200px;
float: left;
.row{
width:100%;
height:45px;
font-size: 13px;
.th{
height:22px !important;
}
.col{
float: left;
width: 15.5%;
// height: 45px;
height: 100%;
line-height: 25px;
text-align: center;
overflow: hidden;
// white-space:nowrap;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2; /*要显示的行数*/
-webkit-box-orient: vertical;
margin-bottom: 10px;
.vrb{
background: #00a0e9 !important;
color:#FFFFFF !important;
}
.vrbre{
background:1px solid #FFFFFF !important;
color:#FFFFFF !important;
}
}
.colre{
width:25% !important;
height:53px !important;
}
}
.tbd{
width: 100%;
height: 220px;
overflow: auto;
.row{
width:100%;
height:110px;
.th{
height:22px !important;
}
.col{
float: left;
width: 15.5%;
// height: 45px;
height: 100%;
line-height: 25px;
text-align: center;
overflow: hidden;
// white-space:nowrap;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2; /*要显示的行数*/
-webkit-box-orient: vertical;
margin-bottom: 10px;
.vrb{
background: #00a0e9 !important;
color:#FFFFFF !important;
}
.vrbre{
background: rgb(8,66,173) !important;
border:1px solid #FFFFFF !important;
color:#FFFFFF !important;
}
}
.colre{
width:25% !important;
height:53px !important;
}
.colot{
text-overflow: none;
}
}
}
.tbd::-webkit-scrollbar {
display: none;
}
}
.tablere{
margin-left: 7% !important;
}
}
}
@media screen and (max-width: 1366px) {
.backgroundt{
width:1059px;
height: 649px;
// background-size: 100% 100%;
background: url(./../../../../images/opening/vroomre.png) center center;
overflow: auto;
.date{
width: 7%;
margin-left: 15%;
// padding-top: 15%;
padding-top: 170px;
font-size: 12px;
float: left;
color: #FFFFFF;
}
.table{
margin:auto 0;
width: 43.5%;
margin-left: 7%;
font-size: 12px;
color:#FFFFFF;
// padding-top: 13%;
padding-top: 137px;
float: left;
.row{
width:100%;
height:45px;
.th{
height:22px !important;
}
.col{
float: left;
width: 15.9%;
height: 45px;
line-height: 25px;
text-align: center;
overflow: hidden;
// white-space:nowrap;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2; /*要显示的行数*/
-webkit-box-orient: vertical;
margin-bottom: 10px;
.vrb{
margin-left: -7px;
background: #00a0e9 !important;
color:#FFFFFF !important;
font-size: 12px !important;
}
.vrbre{
margin-left: -7px;
background:1px solid #FFFFFF !important;
color:#FFFFFF !important;
font-size: 12px !important;
}
}
.colre{
width:25% !important;
height:53px !important;
}
}
.tbd{
width: 100%;
height: 120px;
overflow: auto;
.row{
width:100%;
height:20px;
.th{
height:20px !important;
}
.col{
float: left;
width: 15.9%;
height: 45px;
line-height: 25px;
text-align: center;
overflow: hidden;
// white-space:nowrap;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2; /*要显示的行数*/
-webkit-box-orient: vertical;
margin-bottom: 10px;
.vrb{
margin-left: -7px;
background: #00a0e9 !important;
color:#FFFFFF !important;
font-size: 12px !important;
}
.vrbre{
margin-left: -7px;
background:1px solid #FFFFFF !important;
color:#FFFFFF !important;
font-size: 12px !important;
}
}
.colre{
width:25% !important;
height:53px!important;
}
}
}
.tbd::-webkit-scrollbar {
display: none;
}
}
.tablere{
margin-left: 7% !important;
}
}
}

View File

@ -0,0 +1,445 @@
import React, { useEffect, useRef, useState, } from 'react';
import { Tabs, Spin, message, Popconfirm, Button, Statistic, Tag, Modal, Progress, Card } from 'antd';
// import ProTable, { ActionType, ProColumns } from '@ant-design/pro-table';
// import Xuni from '../../../../images/Xuni/xuni.jpg';
import { updateState, getList, getListGys } from './service';
import { getProId, getSessionUserData, getSessionRoleData } from '@/utils/session';
import FileDown from '@/utils/Download';
import { getURLInformation } from '@/utils/CommonUtils'
import '@/assets/xsy_style.less'
import './vroom.less'
import Datetime from './../../../../components/Date/Datetime'
const { Countdown } = Statistic;
import { getRoomList, jieMi, jmRate, singBid, endTimeUp, updatePrice, queryFx, confirmOffer } from './../Room/service';
import { ipassDecrypt } from "@/utils/IpassVerification";
import { AsymDecrypt } from '@/utils/zwPlugin';
//开标
const open = async (fields: any) => {
const hide = message.loading('正在开启');
try {
const success = await updateState({ ...fields }).then((res) => {
return res.success
});
hide();
if (success) {
message.success('开启成功');
return true;
} else {
return false;
}
} catch (error) {
hide();
message.error('开启失败请重试!');
return false;
}
};
//取消开标
const cancel = async (fields: any) => {
const hide = message.loading('正在取消');
try {
const success = await updateState({ ...fields }).then((res) => {
return res.success
});
hide();
if (success) {
message.success('取消成功');
return true;
} else {
return false;
}
} catch (error) {
hide();
message.error('取消失败请重试!');
return false;
}
};
//取参数
function getQueryString(name: any) {
let reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
let r = window.location.search.substr(1).match(reg);
return r !== null ? unescape(r[2]) : null;
}
const vroom: React.FC<{}> = () => {
const roomType = getURLInformation('roomType');
//控制字段 角色、开标状态、唱标阶段、是否需要ipass解密
const juese = getSessionRoleData().roleCode//daili 代理 gys 供应商
const [data, dataSet] = useState<any>([]);
const [count, countSet] = useState<any>(0);
const [pageData, pageDataSet] = useState<any>({
pageNo: 1,
pageSize: 100,
});
const [loading, setSpin] = useState<any>(false);
const [time, setTime] = useState<any>(Date.now() + 1000 * 60 * 60 * 24 + 1000 * 30);
const [open, setOpen] = useState<any>(true);
const [sertion, setSertion] = useState<any>({});
const [price, setPrice] = useState<number>(0);
const [dis, disSet] = useState<boolean>(false);
const [tFile, tFileSet] = useState<any>([]);//供应商解密存秘钥
const [tdocId, tdocIdSet] = useState<any>('');//tdocId 分项报价表用
const [rateVis, handleRateVis] = useState<boolean>(false); //进度显隐
const [rateCount, rateCountSet] = useState<number>(0); //查询进度启动器
const [jmFileCount, jmFileCountSet] = useState<number>(0);//文件总数
const [jmComplete, jmCompleteSet] = useState<number>(0);//已解密成功
const [jmWait, jmWaitSet] = useState<number>(0);//未解密
const [jmFail, jmFailSet] = useState<number>(0);//解密失败
useEffect(() => {
// setSpin(true)
if (juese === 'daili') {
getData();
} else if (juese === 'gys') {
getDataGys();
}
setTimeout(() => {
countSet(count + 1)
}, 2000);
}, [count, pageData])
async function getData() {//代理获取列表
await getList({ projectId: getProId(), ...pageData, roomType: roomType }).then((res) => {
if (res.code == 200) {
let z = 1;
for (let t of res.data.records) {
t.index = z;
z++;
}
dataSet(res.data);
}
// setSpin(false)
})
}
async function getDataGys() {//供应商获取列表
await getListGys({ projectId: getProId(), ...pageData, roomType: roomType }).then((res) => {
if (res.code == 200) {
let z = 1;
for (let t of res.data.records) {
t.index = z;
z++;
}
dataSet(res.data);
}
// setSpin(false)
})
}
const datat = [{
index: "1",
sectionName: "标段一",
sectionNo: "NF020910/2",
dateTime: "2021-03-01 15:18:27",
roomState: "1"
}, {
index: "2",
sectionName: "标段二",
sectionNo: "NF020910/2",
dateTime: "2021-03-01 15:18:27",
roomState: "2"
}, {
index: "3",
sectionName: "标段三",
sectionNo: "NF020910/2",
dateTime: "2021-03-01 15:18:27",
roomState: "1"
}, {
index: "4",
sectionName: "标段私",
sectionNo: "NF020910/2",
dateTime: "2021-03-01 15:18:27",
roomState: "1"
}, {
index: "5",
sectionName: "标段五",
sectionNo: "NF020910/2",
dateTime: "2021-03-01 15:18:27",
roomState: "1"
}]
const renderOperation = (item: any) => {
return <> {item.roomState == 0 && juese === 'daili' ? <Button onClick={async () => {
//到时间了
const success = await open({ id: item.id, roomState: 1, projectId: item.projectId, sectionId: item.sectionId });
if (success) {
window.open(`/room/index?aa=${item.assessRoomId}&bb=${item.turnSort}&roomType=${roomType}`);
}
// actionRef.current?.reload();
// setSpin(false);
}} className="vrb" style={{ fontSize: "10px", marginBottom: "10px", marginRight: "3px" }} size="small"></Button> : null}
{(item.roomState == 1 || item.roomState == 2 || item.roomState == 3) && juese === 'daili' ?
<Button onClick={() => {
if (juese == "gys") {
// 供应商进入开标室
setOpen(false)
getTableData()
} else {
window.open(`/room/index?aa=${item.assessRoomId}&bb=${item.turnSort}&roomType=${roomType}`)
}
}} className="vrb" style={{ fontSize: "10px", marginBottom: "10px" }} size="small"></Button> : null}
{juese === 'daili' && item.roomState != 3 && item.roomState != 4 ?
<Popconfirm
// placement="topRight"
title={"确定取消开标么?"}
onConfirm={() => { confirm(item.id); }}
okText="确定"
cancelText="取消"
>
<Button className="vrbre" style={{ fontSize: "10px", marginBottom: "10px", marginLeft: "-9px" }} size="small"></Button>
</Popconfirm> : null}
{juese === 'daili' ?
<FileDown
apiUrl={`/api/biz-service-ebtp-opening/v1/bizbidopenroom/exportTenderRecords/${item.sectionId}?roomType=${roomType}`}
method='GET'
fileName={`${item.projectName}-${item.sectionName}-投递记录`}
type='xlsx'
btnName='导出投递记录'
tag='vrbre'
style={{ marginLeft: "12px" }}
/> : null}
{juese === 'gys' && item.roomState == 1 && roomType === '2' ?
<Button type='text' onClick={async () => {
window.open(`/room/index?aa=${item.assessRoomId}&bb=${item.turnSort}`);
// actionRef.current?.reload();
// setSpin(false);
}} className="vrb"></Button>
: null}
</>
}
const renderOperationt = (item: any) => {
return <><Button className="vrb" size="small" style={{ float: "left" }}
onClick={async () => {
disSet(true);
let secretKeyMap: any = {};
if (tFile.length > 0) {
if (ipassDecrypt(tFile[0].secretKey) != null) {
await tFile.map((item: any) => {
secretKeyMap[item.id] = AsymDecrypt(item.secretKey);
})
}
}
if (Object.keys(secretKeyMap).length > 0) {
const success = await jieMi({ tdocId: tdocId, secretKeyMap: secretKeyMap }).then((res) => {//roomType: roomType
return res.success
});
if (success) {
handleRateVis(true);
rateCountSet(rateCount + 1);
}
} else { message.error('没有需要解密的文件') }
disSet(false);
}} disabled={dis}></Button>
<Button className="vrb" size="small" style={{ float: "left", marginLeft: "10px" }} onClick={() => {
disSet(true);
handleRateVis(true);
rateCountSet(rateCount + 1);
disSet(false);
}}></Button>
<Button className="vrb" size="small" style={{ float: "left" }}></Button>
</>
}
const confirm = async (roomId: any) => {
cancel({ id: roomId, roomState: 4 });
// success ? actionRef.current?.reload() : null;
// setSpin(false);
}
//解密
const sing = async (fields: any) => {
try {
const success = await singBid({ ...fields }).then((res) => {
return res.success
});
if (success) {
message.success('操作成功!');
getTableData();
return true;
} else {
return false;
}
} catch (error) {
message.error('失败请重试!');
return false;
}
};
//取表格数据
const getTableData = async () => {
let assessRoomId: any = "";
let turnSort: any = '';
let commpanyId = getSessionUserData().organizationId;
juese == 'daili' ? commpanyId = '' : null;
if (getQueryString("aa") != null) {
assessRoomId = getQueryString("aa")
}
if (getQueryString("bb") != null) {
turnSort = getQueryString("bb")
}
let sertion = {
sectionName: "",
sectionNo: "",
decryptEndDateT: "",
endTimeVisT: false,
isdet: false
}
let tdocId = "";
let price = 0;
await getRoomList({ assessRoomId: assessRoomId, turnSort: turnSort, commpanyId: commpanyId }).then((res) => {
if (res.data != undefined) {
sertion.sectionName = res.data.singConfig.sectionName;
sertion.sectionNo = res.data.singConfig.sectionNo;
sertion.decryptEndDateT = res.data.tdoc.decryptEndDate == null ? '' : res.data.tdoc.decryptEndDate;
sertion.endTimeVisT = res.data.tdoc.decryptEndDate == null ? true : false;
tdocId = res.data.tdoc.id;
tdocIdSet(res.data.tdoc.id)
for (let t of res.data.suppliers) {
if (t.companyId == commpanyId) {
const keys = Object.keys(t.dataMap);
const tlist = keys.map(item => {
return { key: item, value: t.dataMap[item] };
})
price = tlist.pop().value;
}
}
}
})
let all: number, comp: number, fail: number, wait: number = 0;
await jmRate({ tdocId: tdocId }).then((res) => {
if (data != undefined) {
all = data['-1'] != undefined ? parseInt(data['-1']) : 0;
comp = data['1'] != undefined ? parseInt(data['1']) : 0;
fail = data['2'] != undefined ? parseInt(data['2']) : 0;
wait = data['0'] != undefined ? parseInt(data['0']) : 0;
}
jmCompleteSet(comp);
jmFailSet(fail);
jmFileCountSet(all);
jmWaitSet(wait);
if (all != wait) {
sertion.isdet = true
} else {
sertion.isdet = false
}
})
setSertion(sertion)
}
const jmjd = () => {
return (
<Modal
title="解密进度"
width={'800px'}
destroyOnClose
centered
bodyStyle={{ padding: '32px 40px 48px', overflowY: 'auto' }}
visible={rateVis}
footer={false}
onCancel={() => { countSet(count + 1); handleRateVis(false); }}
>
<Card bordered={false} style={{ textAlign: 'center', fontSize: '30px', }}>
{(jmComplete + jmFail == jmFileCount && jmFileCount !== 0) ? `解 密 结 束`:`正 在 解 密...`}
</Card>
<Progress percent={Math.floor((jmComplete / jmFileCount) * 100)} status="active" />
<div style={{ textAlign: "center" }}>
<span style={{ fontSize: 30, color: 'rgb(0,144,255)' }}>{jmFileCount}</span>
</div>
<div style={{ textAlign: "center" }}>
<span style={{ fontSize: 30, color: 'rgb(61,169,92)' }}>{jmComplete}</span> ,
{/* 排队解密中:<span style={{ fontSize: 30, color: 'red' }}>{100 - rate}</span> 个, */}
<span style={{ fontSize: 30, color: 'rgb(0,144,255)' }}>{jmWait}</span> ,
<span style={{ fontSize: 30, color: 'red' }}>{jmFail}</span>
</div>
</Modal>
)
}
return open ? (
<>
<div className="backgroundt">
<Datetime className="date" />
<div className="table">
<div className="row">
<div className="col th"></div>
<div className="col th"></div>
<div className="col th"></div>
<div className="col th"></div>
<div className="col th"></div>
<div className="col th"></div>
</div>
<Spin spinning={loading}>
<div className="tbd">
{data != "" && data.records.map((item) => {
{/* {datat.map((item)=>{ */ }
let roomState = "";
switch (item.roomState) {
case "0": roomState = "未开标"; break;
case "1": roomState = "已开标"; break;
case "2": roomState = "唱标中"; break;
case "3": roomState = "唱标结束"; break;
case "4": roomState = "已取消"; break;
}
return <div className="row">
<div className="col" title={item.index}>{item.index}</div>
<div className="col" title={item.sectionName}>{item.sectionName}</div>
<div className="col" title={item.sectionNo}>{item.sectionNo}</div>
<div className="col" title={item.opingTime}>{item.opingTime}</div>
<div className="col" title={roomState}>{roomState}</div>
<div className="col colot">
{renderOperation(item)}
</div>
</div>
})}
</div>
</Spin>
</div>
</div>
</>
) : (<>
<div className="backgroundt">
<div className="date">
{/* 距开标还有
<Countdown value={time}
valueStyle={{color:"#FFFFFF",fontSize:"15px",fontWeight:"300"}}
format="D天 H时 m分 s秒"
title="距开标还有"
onFinish={onFinish}
/> */}
</div>
<div className="table tablere">
<div className="row">
<div className="col colre th"></div>
<div className="col colre th"></div>
<div className="col colre th"></div>
<div className="col colre th"></div>
</div>
<Spin spinning={loading}>
<div className="tbd">
{sertion != {} ? sertion => {
return <div className="row">
<div className="col colre" title={sertion.sectionName}>{sertion.sectionName}</div>
<div className="col colre" title={sertion.sectionNo}>{sertion.sectionNo}</div>
<div className="col colre" title={sertion.isdet}>
{sertion.isdet ? <Tag color="#18bbbd"></Tag> : <Tag color="#18bbbd"></Tag>}
</div>
<div className="col colre">
{renderOperationt(item)}
</div>
<div>
<div style={{ width: "100%", fontSize: "15px", color: "#00a0e9", padding: "0 20px 0 20px" }}>178000000
</div>
<div style={{
fontSize: "7px", color: "#f5c23f", float: 'right',
marginRight: "20px", position: "relative", top: "-25px"
}}><p style={{ color: "#FFFFFF", fontSize: "7px", fontWeight: "300" }}>{sertion.endTimeVisT}</p>
{/* <Countdown value={sertion.endTimeVisT}
valueStyle={{color:"#FFFFFF",fontSize:"7px",fontWeight:"300"}}
format="D天 H时 m分 s秒"
title="距开标还有"
onFinish={onFinish}
/> */}
</div>
</div>
</div>
} : <></>}
</div>
</Spin>
{jmjd()}
</div>
</div>
</>)
}
export default vroom;

View File

@ -1,11 +1,12 @@
@import '~antd/lib/style/themes/default.less';
.header {
background-color: rgb(170, 0, 0);
background-color: #b30000;
color: white;
font-size: 40px;
height: 70px;
font-weight: 800;
font-size: 16px;
height: 56px;
line-height: 56px;
font-weight: 600;
display: flex;
.headerAlign {
align-self: center;
@ -22,14 +23,17 @@
}
.titleTop {
font-size: 30px;
font-weight: 600;
font-weight: 400;
text-align: center;
background-color: aliceblue;
}
.desStyle{
background-color: white;
padding: 0px 24px;
margin-top: 16px;
.ant-descriptions-item-label{
text-align: center;
background-color: white;
text-align: right;
font-size: 20px;
min-width: 200px;
}
@ -39,7 +43,22 @@
max-width: 750px;
}
}
.xsy-tools-div{
width:100%;
height:32px;
padding:0px 24px;
}
.xsy-table-header{
font-size: 20px;
}
.xsy-table{
background-color: white;
padding:0px 24px;
margin-top:10px;
.ant-table-cell{
font-size: 20px;
}
}
:global {
.drawerStyle {
.ant-drawer-content-wrapper {

File diff suppressed because it is too large Load Diff

View File

@ -1,14 +1,32 @@
import request from '@/utils/request';
import { getSessionRoleData } from '@/utils/session';
//获取列表
export async function getList(params?: any) {
return request(`/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderList`,{
let url = '/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderList';
if(getSessionRoleData().roleCode === 'ebtp-supplier'){//ebtp-agency-project-manager 代理 ebtp-supplier 供应商
url = '/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderListBySupplier'
}
return request(url,{
method:'POST',
data:{
...params
}
});
}
export async function getRoomList(params?: any) {
let url = '/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderList';
if(getSessionRoleData().roleCode === 'ebtp-supplier'){
url = '/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderListBySupplier'
}
return request(url,{
method:'POST',
data:{
...params
}
});
}
//获取开标状态及信息列表数据
export async function getOpenDt(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidsingconfigure/getlist`,{
@ -29,9 +47,11 @@ export async function singBid(params?: any) {
}
//解密
export async function jieMi(params?: any) {
console.log(params);
return request(`/api/biz-service-ebtp-resps/v1/tfile/executeDecrypt`,{
let url = '/api/biz-service-ebtp-resps/v1/tfile/executeDecrypt';
if(getSessionRoleData().roleCode === 'ebtp-supplier'){
url = '/api/biz-service-ebtp-resps/v1/tfile/executeDecryptBySupplier'
}
return request(url,{
method:'POST',
data:{
...params
@ -40,7 +60,11 @@ export async function jieMi(params?: any) {
}
//解密进度
export async function jmRate(params?: any) {
return request(`/api/biz-service-ebtp-resps/v1/tfile/getDecryptProgress`,{
let url = '/api/biz-service-ebtp-resps/v1/tfile/getDecryptProgress';
if(getSessionRoleData().roleCode === 'ebtp-supplier'){
url = '/api/biz-service-ebtp-resps/v1/tfile/getDecryptProgressBySupplier'
}
return request(url,{
method:'POST',
data:{
...params
@ -49,8 +73,8 @@ export async function jmRate(params?: any) {
}
//设置解密时限
export async function endTimeUp(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidopenroom/updateOpenRoom/`,{
method:'PUT',
return request(`/api/biz-service-ebtp-resps/v1/tdoc/updateTdocDecryptEndDate`,{
method:'POST',
data:{
...params
}
@ -58,7 +82,7 @@ export async function endTimeUp(params?: any) {
}
//补录报价
export async function updatePrice(params?: any) {
return request(`/api/biz-service-ebtp-resps/v1/tfiletendererprice`,{
return request(`/api/biz-service-ebtp-resps/v1/tfilecontentdata/insertPrice`,{
method:'POST',
data:{
...params
@ -74,7 +98,7 @@ export async function queryFx(params?: any) {
}
});
}
//查看分项报价
export async function confirmOffer(reviewTurnId?: any) {
return request(`/api/biz-service-ebtp-tender/v1/supplier_register/update/sign/${reviewTurnId}`);
//供应商确认报价
export async function confirmOffer(reviewTurnId?: any,tdocId?: any) {
return request(`/api/biz-service-ebtp-tender/v1/supplier_register/update/sign/${reviewTurnId}?tdocId=${tdocId}`);
}

View File

@ -1,56 +0,0 @@
@import '~antd/lib/style/themes/default.less';
.header {
background-color: rgb(170, 0, 0);
color: white;
font-size: 40px;
height: 70px;
font-weight: 800;
display: flex;
.headerAlign {
align-self: center;
margin-left: 20px;
}
.proName {
font-size: 30px;
font-weight: 300;
}
.closeButton{
position: absolute;
right: 20px;
}
}
.titleTop {
font-size: 30px;
font-weight: 600;
text-align: center;
background-color: aliceblue;
}
.desStyle{
background-color: white;
.ant-descriptions-item-label{
text-align: center;
font-size: 20px;
min-width: 200px;
}
.ant-descriptions-item-content{
font-size: 20px;
min-width: 300px;
max-width: 750px;
}
}
:global {
.drawerStyle {
.ant-drawer-content-wrapper {
.ant-drawer-content {
height: 100%;
.ant-drawer-wrapper-body {
.ant-drawer-body {
padding: 0px;
}
}
}
}
}
}

View File

@ -1,465 +0,0 @@
import ProTable, { ActionType, ProColumns } from "@ant-design/pro-table";
import { Button, Col, Descriptions, Form, Input, message, Modal, Progress, Row, Spin } from "antd";
import React, { useEffect, useRef, useState } from "react";
import styles from './index.less';
import './index.less';
import { getList, jieMi, jmRate, singBid, endTimeUp } from './service';
const Room: React.FC<{}> = () => {
const [spin, spinSet] = useState<any>(false);
const [form] = Form.useForm();
const FormItem = Form.Item;
const { TextArea } = Input;
const formLayout = {
labelCol: { span: 8 },
wrapperCol: { span: 16 },
};
//控制字段 角色、开标状态、唱标阶段、是否需要ipass解密
// const proId = 1111111;
const juese = 1//1代理 2供应商
const actionRef = useRef<ActionType>();
const [projectName, projectNameSet] = useState<any>(''); //项目名称
const [projectNo, projectNoSet] = useState<any>(''); //项目名称
const [sectionName, sectionNameSet] = useState<any>(''); //项目名称
const [sectionNo, sectionNoSet] = useState<any>(''); //项目名称
const [openTime, openTimeSet] = useState<any>(''); //项目名称
const [openState, openStateSet] = useState<boolean>();//是否开标
const [range, rangeSet] = useState<boolean>();//是否唱标
const [jm, jmSet] = useState<boolean>();//是否解密
const [rangeOver, rangeOverSet] = useState<boolean>();//是否唱标结束
const [important, importantSet] = useState<boolean>();//是否重大项目
const [turnId, turnIdSet] = useState<any>('');//是否重大项目
const [configId, configIdSet] = useState<any>('');//唱标配置id
const [openRoom, openRoomSet] = useState<any>('');//开标室id
const [repairVis, handleRepairVis] = useState<boolean>(false);//补录报价显隐
const [subentryVis, handleSubentryVis] = useState<boolean>(false);//分项报价显隐
const [jmTimeVis, jmTimeVisSet] = useState<boolean>(false);//解密时限显隐
const [endTime, endTimeSet] = useState<any>();//解密时限
const [rateVis, handleRateVis] = useState<boolean>(false); //进度显隐
const [rateCount, rateCountSet] = useState<number>(0); //查询进度启动器
const [jmFileCount, jmFileCountSet] = useState<number>(0);//文件总数
const [jmComplete, jmCompleteSet] = useState<number>(0);//已解密成功
const [jmWait, jmWaitSet] = useState<number>(0);//未解密
const [jmFail, jmFailSet] = useState<number>(0);//解密失败
const [dis, disSet] = useState<boolean>();//解密失败
//开标室表格
const [columnsKb, columnsKbSet] = useState<any>([]);
const [columnsKbData, columnsKbDataSet] = useState<any>([]);
//分项报价表格
const columnsFx: ProColumns<any>[] = [
{ title: '序号', dataIndex: 'index', valueType: 'index', },
{ title: '商品名称', dataIndex: 'name', },
{ title: '数量', dataIndex: 'count', },
{ title: '规格', dataIndex: 'type', },
{ title: '价格', dataIndex: 'price', valueType: "money" },
]
//解密
const sing = async (fields: any) => {
const hide = message.loading('正在配置');
try {
await singBid({ ...fields });
hide();
message.success('成功!');
getTableData();
return true;
} catch (error) {
hide();
message.error('失败请重试!');
return false;
}
};
//设置解密时限
const endTimeConfig = async (fields: any) => {
const hide = message.loading('正在配置');
try {
await endTimeUp({ ...fields });
hide();
message.success('配置成功!');
return true;
} catch (error) {
hide();
message.error('配置失败请重试!');
return false;
}
};
//开标室表格按钮
const tools = [
juese == 1 && !important && !range ? <Button key='jm' type="primary" onClick={() => { jmTimeVisSet(true) }}></Button> : null,
juese == 1 && !range ? <Button key='jm' type="primary"
onClick={async () => {
spinSet(true);
const success = await jieMi({ turnId: turnId });
if (success) {
handleRateVis(true);
rateCountSet(rateCount + 1);
}
spinSet(false);
}}></Button> : null,
juese == 1 && !range ? <Button key='ckjd' type="primary"
onClick={() => {
handleRateVis(true);
rateCountSet(rateCount + 1);
}}></Button> : null,
juese == 1 && (jmComplete+jmFail)>0 && !rangeOver ? <Button key='cb' type="primary" onClick={() => { sing({ id: configId, whetherRange: 1 }); }}></Button> : null,
juese == 1 && range && !rangeOver ? <Button key='cbjs' type="primary" onClick={() => { sing({ id: configId, whetherRangeOver: 1 }); }}></Button> : null,
juese == 1 ? <Button key='dy' type="primary" onClick={() => { }}></Button> : null,
];
//取参数
function getQueryString(name: any) {
let reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
let r = window.location.search.substr(1).match(reg);
return r !== null ? unescape(r[2]) : null;
}
//进页面执行
useEffect(() => {
getTableData();
}, []);
//查询进度
useEffect(() => {
if (rateVis) {
let all: number, comp: number, fail: number, wait: number = 0;
jmRate({ turnId: turnId }).then((res) => {
console.log(res);
let data = res.data;
if (data != undefined) {
all = data['-1'] != undefined ? data['-1'] : 0;
comp = data['1'] != undefined ? data['1'] : 0;
fail = data['2'] != undefined ? data['2'] : 0;
wait = data['0'] != undefined ? data['0'] : 0;
}
jmCompleteSet(comp);
jmFailSet(fail);
jmFileCountSet(all);
jmWaitSet(wait);
});
setTimeout(async () => {
rateCountSet(rateCount + 1);
}, 2000);
}
}, [rateCount]);
//取表格数据
const getTableData = async () => {
spinSet(true);
let assessRoomId: any = "";
let turnSort: any = '';
if (getQueryString("aa") != null) {
assessRoomId = getQueryString("aa")
}
if (getQueryString("bb") != null) {
turnSort = getQueryString("bb")
}
await getList({ assessRoomId: assessRoomId, turnSort: turnSort }).then((res) => {
console.log(res);
let column = [];
let data: any = [];
let category: any[] = [];
let projectName: any, projectNo: any, sectionName: any, sectionNo: any, openTime: any, turnId: any, configId: any, openRoomId: any = '';
let openState: any, range: any, rangeOver: any, decryptStatus: any, important: any = false;
if (res.data != undefined) {
//拼表格
column.push({ title: '序号', dataIndex: 'index', valueType: 'index', });
column.push({ title: '投标单位', dataIndex: 'companyName', });
res.data.title.map((item: any, index: any) => {
column.push({ title: item.name, dataIndex: item.id, });
category.push(item.id);
});
column.push({ title: '签名信息', dataIndex: 'bidUserName', });
column.push({
title: '操作', dataIndex: 'option', width: 300,
valueType: 'option',
render: (_: any, record: any) => {
return (
<>
<Button key='blbj' type="primary" onClick={() => { handleRepairVis(true) }} ></Button>
<Button key='ckfxbj' onClick={() => { handleSubentryVis(true) }}></Button>
</>
)
}
});
//拼data
res.data.suppliers != undefined ? res.data.suppliers.map((item1: any, index: any) => {
let oneGys = {};
oneGys["key"] = index;
oneGys["companyName"] = item1.companyName;
oneGys["bidUserName"] = item1.bidUserName + "(" + item1.signTime + ")";
category.map((item2: any, index: any) => {
oneGys[item2] = item1.dataMap[item2];
});
data.push(oneGys);
}) : null;
//拼记录表信息
if (res.data != undefined) {
projectName = res.data.singConfig.projectName;
projectNo = res.data.singConfig.projectNo;
sectionName = res.data.singConfig.sectionName;
sectionNo = res.data.singConfig.sectionNo;
openTime = res.data.singConfig.openTime;
openState = res.data.singConfig.openState == 1 ? true : false;
range = res.data.singConfig.whetherRange == 1 ? true : false;
rangeOver = res.data.singConfig.whetherRangeOver == 1 ? true : false;
decryptStatus = res.data.singConfig.decryptStatus == 1 ? true : false;
important = res.data.singConfig.passDecode == 1 ? true : false;
turnId = res.data.singConfig.turnId;
configId = res.data.singConfig.id;
openRoomId = res.data.singConfig.openRoomId;
important = res.data.singConfig.passDecode == 1 ? true : false;
}
}
columnsKbSet(column);
columnsKbDataSet(data);
projectNameSet(projectName);
projectNoSet(projectNo);
sectionNameSet(sectionName);
sectionNoSet(sectionNo);
openTimeSet(openTime);
openStateSet(openState);
rangeSet(range);
rangeOverSet(rangeOver);
jmSet(decryptStatus);
turnIdSet(turnId);
configIdSet(configId);
openRoomSet(openRoomId);
importantSet(important);
});
spinSet(false);
}
// const getOpenData = async () => {
// let assessRoomId: any = "";
// let projectName: any, projectNo: any, sectionName: any, sectionNo: any, openTime: any = '';
// let openState: any, range: any, rangeOver: any, jm: any = false;
// if (getQueryString("aa") != null) {
// assessRoomId = getQueryString("aa")
// }
// await getOpenDt({ assessRoomId }).then((res) => {
// // console.log(res.data);
// if (res.data != undefined && res.data.length == 1) {
// projectName = res.data[0].projectName;
// projectNo = res.data[0].projectNo;
// sectionName = res.data[0].sectionName;
// sectionNo = res.data[0].sectionNo;
// openTime = res.data[0].openTime;
// openState = res.data[0].openState == 1 ? true : null;
// range = res.data[0].whetherRange == 1 ? true : null;
// rangeOver = res.data[0].whetherRangeOver == 1 ? true : null;
// }
// });
// projectNameSet(projectName);
// projectNoSet(projectNo);
// sectionNameSet(sectionName);
// sectionNoSet(sectionNo);
// openTimeSet(openTime);
// openStateSet(openState);
// rangeSet(range);
// rangeOverSet(rangeOver);
// }
//开标记录表
const kbjl = () => {
return (
<>
<div className={styles.titleTop}>
<div style={{ backgroundColor: 'white' }}><span style={{ letterSpacing: "50px" }}></span></div>
</div>
<div className="desStyle">
<Descriptions bordered column={2} size="small">
<Descriptions.Item label="项目名称" className={styles.desItemStyle} span={2}>{projectName}</Descriptions.Item>
<Descriptions.Item label="项目编号" className={styles.desItemStyle}>{projectNo}</Descriptions.Item>
<Descriptions.Item label="标包名称" className={styles.desItemStyle}>{sectionName}</Descriptions.Item>
<Descriptions.Item label="标段编号" className={styles.desItemStyle}>{sectionNo}</Descriptions.Item>
<Descriptions.Item label="开标时间" className={styles.desItemStyle}>{openTime}</Descriptions.Item>
</Descriptions>
</div>
<ProTable
actionRef={actionRef}
columns={columnsKb}//表格
dataSource={columnsKbData}
search={false}
size={'small'}
rowSelection={false}
toolBarRender={() => tools}
pagination={{ defaultPageSize: 10 }}//默认显示条数
/>
</>
)
}
//补录报价
const blbj = () => {
return (
<Modal
title="补录报价"
width={'800px'}
destroyOnClose
centered
bodyStyle={{ padding: '32px 40px 48px', overflowY: 'auto' }}
visible={repairVis}
onCancel={() => handleRepairVis(false)}
>
<Form
{...formLayout}
form={form}
>
<Row>
<Col span={22}><FormItem
name="company"
label="投标单位"
>
<Input bordered={false} readOnly defaultValue="华为技术有限公司" />
</FormItem></Col>
</Row>
<Row>
<Col span={22}><FormItem
name="bid"
label="标包"
>
<Input bordered={false} readOnly defaultValue="包1" />
</FormItem></Col>
</Row>
<Row>
<Col span={22}><FormItem
name="money"
label="报价(单位:元)"
>
<Input />
</FormItem></Col>
</Row>
<Row>
<Col span={22}><FormItem
name="baozheng"
label="投标保证金"
>
<TextArea />
</FormItem></Col>
</Row>
<Row>
<Col span={22}><FormItem
name="remark"
label="备注"
>
<TextArea />
</FormItem></Col>
</Row>
</Form>
</Modal>
)
}
//解密进度
const jmjd = () => {
return (
<Modal
title="解密进度"
width={'800px'}
destroyOnClose
centered
bodyStyle={{ padding: '32px 40px 48px', overflowY: 'auto' }}
visible={rateVis}
footer={false}
onCancel={() => { getTableData(); handleRateVis(false); }}
>
{/* <img src={timg} alt="" width='100%' height="75%" /> */}
<Progress percent={(jmComplete + jmFail) * 100 / jmFileCount} status="active" />
<div style={{ textAlign: "center" }}>
<span style={{ fontSize: 30, color: 'rgb(0,144,255)' }}>{jmFileCount}</span>
</div>
<div style={{ textAlign: "center" }}>
<span style={{ fontSize: 30, color: 'rgb(61,169,92)' }}>{jmComplete}</span> ,
{/* 排队解密中:<span style={{ fontSize: 30, color: 'red' }}>{100 - rate}</span> 个, */}
<span style={{ fontSize: 30, color: 'rgb(0,144,255)' }}>{jmWait}</span> ,
<span style={{ fontSize: 30, color: 'red' }}>{jmFail}</span>
</div>
</Modal>
)
}
//分项报价表
const fxbj = () => {
return (
<Modal
title="分项报价表"
width={'60%'}
destroyOnClose
bodyStyle={{ padding: '32px 40px 48px', overflowY: 'auto' }}
visible={subentryVis}
footer={false}
onCancel={() => handleSubentryVis(false)}
>
<ProTable
columns={columnsFx}//表格
dataSource={columnsKbData}
search={false}
size={'small'}
rowSelection={false}
options={false}
pagination={{ defaultPageSize: 10 }}//默认显示条数
/>
</Modal>
)
}
//解密时限
const jmTime = () => {
return (
<>
<Modal
title="设置解密时限"
width={'400px'}
destroyOnClose
centered
bodyStyle={{ overflowY: 'auto' }}
visible={jmTimeVis}
onCancel={() => { jmTimeVisSet(false); }}
onOk={() => {
endTimeConfig({ id: openRoom, opingTimeLimit: endTime });
jmTimeVisSet(false);
}}
>
<Input type='number' style={{width:'80px'}} value={endTime} onChange={(event) => {
endTimeSet(event.target.value);
}} />
</Modal>
</>
)
}
//未开标
let height = document.body.clientHeight - 70;
// function notOpen() {
// return (
// <div style={{ width: '100%', height: `${height}px`, paddingTop: `${0.4 * height}px`, backgroundColor: 'white', textAlign: 'center' }}>
// <div style={{}}>暂未开标</div>
// </div>
// )
// }
return (
<>
<div className={styles.header}>
<div className={styles.headerAlign}>
<span></span>
</div>
</div>
<Spin spinning={spin} size='large'>
<div style={{ width: '100%', height: `${height}px`, backgroundColor: 'white', }}>
{
openState ?
<div>
{/* 开标记录表 */}
{kbjl()}
{/* 补录报价 */}
{blbj()}
{/* 解密进度 */}
{jmjd()}
{/* 分项报价 */}
{fxbj()}
{/* 解密时限 */}
{jmTime()}
</div>
: null
// : <>{notOpen()}</>
}
</div>
</Spin>
</>
)
};
export default Room;

View File

@ -1,60 +0,0 @@
import request from '@/utils/request';
//获取列表
export async function getList(params?: any) {
return request(`/api/biz-service-ebtp-resps/v1/tfile/getOpenTenderList`,{
method:'POST',
data:{
...params
}
});
}
//获取开标状态及信息列表数据
export async function getOpenDt(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidsingconfigure/getlist`,{
method:'POST',
data:{
...params
}
});
}
//唱价
export async function singBid(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidsingconfigure/updateSingConfigure`,{
method:'PUT',
data:{
...params
}
});
}
//解密
export async function jieMi(params?: any) {
console.log(params);
return request(`/api/biz-service-ebtp-resps/v1/tfile/executeDecrypt`,{
method:'POST',
data:{
...params
}
});
}
//解密进度
export async function jmRate(params?: any) {
console.log(params);
return request(`/api/biz-service-ebtp-resps/v1/tfile/getDecryptProgress`,{
method:'POST',
data:{
...params
}
});
}
//设置解密时限
export async function endTimeUp(params?: any) {
return request(`/api/biz-service-ebtp-opening/v1/bizbidopenroom/updateOpenRoom/`,{
method:'PUT',
data:{
...params
}
});
}