更新版本库
This commit is contained in:
@ -1,37 +1,92 @@
|
||||
import React, {useState} from "react";
|
||||
import ProTable from "@ant-design/pro-table";
|
||||
import {Collapse} from "antd";
|
||||
import {Collapse, Modal} from "antd";
|
||||
import {getBidAssessmentResultList} from "@/pages/Calibration/BidAssessmentResults/service";
|
||||
|
||||
interface currentTableProps {
|
||||
thisColumns:any,
|
||||
thisData:any;
|
||||
panelType:any;
|
||||
assessRoomId: any,
|
||||
ChangeNoticeListVisible:boolean,
|
||||
onCancel: () => void;
|
||||
}
|
||||
|
||||
const currentTable: React.FC<currentTableProps> = (props) => {
|
||||
console.log("panelType:"+props.panelType)
|
||||
const [panelType,setPanelType] = useState<any>();
|
||||
// setPanelType(props.panelType);
|
||||
const {Panel} = Collapse;
|
||||
Panel="1";
|
||||
const [pageloading, setPageloading] = useState<boolean>(false);
|
||||
|
||||
const {assessRoomId,ChangeNoticeListVisible,onCancel} =props;
|
||||
const columnsOther: any = [
|
||||
{
|
||||
title: '序号',
|
||||
dataIndex: 'index',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '推送时间',
|
||||
dataIndex: 'createDate',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '推送报文',
|
||||
dataIndex: 'opcontent',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '推送结果',
|
||||
dataIndex: 'opresult',
|
||||
valueType: 'text',
|
||||
valueEnum: {
|
||||
"true": {text: '成功'},
|
||||
"false": {text: '失败'},
|
||||
}
|
||||
},
|
||||
]
|
||||
return (
|
||||
<>
|
||||
<Collapse
|
||||
// defaultActiveKey={panelType}
|
||||
activeKey={props.panelType}
|
||||
bordered={false}
|
||||
ghost={true}
|
||||
<Modal
|
||||
destroyOnClose
|
||||
title={"推送列表"}
|
||||
visible={ChangeNoticeListVisible}
|
||||
onOk={onCancel}
|
||||
onCancel={onCancel}
|
||||
width={1000}
|
||||
closable={false}
|
||||
>
|
||||
<Panel
|
||||
|
||||
header={""} showArrow={false} key={"1"}>
|
||||
<ProTable
|
||||
search={false}
|
||||
options={false}
|
||||
columns={props.thisColumns}
|
||||
dataSource={props.thisData}
|
||||
/>
|
||||
</Panel>
|
||||
</Collapse>
|
||||
<ProTable
|
||||
columns={columnsOther}
|
||||
search={false}
|
||||
options={false}
|
||||
bordered={true}
|
||||
key={Math.random()}
|
||||
request={async (
|
||||
params: {
|
||||
assessRoomId:string;
|
||||
pageSize: number;
|
||||
current: number;
|
||||
},
|
||||
sort,
|
||||
filter,
|
||||
) => {
|
||||
// 这里需要返回一个 Promise,在返回之前你可以进行数据转化
|
||||
// 如果需要转化参数可以在这里进行修改
|
||||
const msg = await getBidAssessmentResultList({
|
||||
assessRoomId:assessRoomId,
|
||||
page: params.current,
|
||||
pageSize: params.pageSize,
|
||||
});
|
||||
return {
|
||||
/* data: msg.result,
|
||||
// success 请返回 true,
|
||||
// 不然 table 会停止解析数据,即使有数据
|
||||
success: boolean,
|
||||
// 不传会使用 data 的长度,如果是分页一定要传
|
||||
total: number,*/
|
||||
}
|
||||
}
|
||||
}
|
||||
// dataSource={[]}
|
||||
// pagination={{pageSize: 50}} scroll={{y: 240}}
|
||||
loading={pageloading}
|
||||
/>
|
||||
</Modal>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
@ -1,121 +1,145 @@
|
||||
import React, {useEffect, useState} from 'react';
|
||||
import {Button, Card, Collapse, Divider, List} from "antd";
|
||||
import style from "@/pages/BiddingAnnouncement/components/style.less";
|
||||
import {Button, Card, Collapse, Divider, List, message, Modal, Table} from "antd";
|
||||
import ProTable from "@ant-design/pro-table";
|
||||
import {DownloadOutlined, UnorderedListOutlined} from "@ant-design/icons/lib";
|
||||
import {getBidAssessmentResultsList} from "./service"
|
||||
import {getBidAssessmentResultList, getBidAssessmentResultsList, pushBidAssessmentResult} from "./service"
|
||||
import CurrentTable from "./components/currentTable"
|
||||
import {getProId} from "@/utils/session";
|
||||
|
||||
interface BiddingDocumentsDecryptProps {
|
||||
projectId: "1331563848498413568";/*?项目id*/
|
||||
}
|
||||
|
||||
const BidAssessmentResults: React.FC<BiddingDocumentsDecryptProps> = (props) => {
|
||||
|
||||
const BidAssessmentResults: React.FC<{}> = (props) => {
|
||||
const [pageloading, setPageloading] = useState<boolean>(false);
|
||||
const [ListData, setListData] = useState<any>();
|
||||
const [activeKey, setActiveKey] = useState<any>([]);
|
||||
const [assessRoomId, setAssessRoomId] = useState<any>();
|
||||
const [currentTable, setCurrentTable] = useState<boolean>(false);
|
||||
const [proID,setProID] = useState<any>(getProId);
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
title: '排名',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
dataIndex: 'sort',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '供应商名称',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'companyName',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '报价(元)',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
dataIndex: 'price',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '评审价(元)',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'priceReview',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '商务分',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
dataIndex: 'businessScore',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '技术分',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'technicalScore',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '服务分',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
dataIndex: 'serviceScore',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '价格分',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'priceScore',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '综合得分',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'totalScore',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '拟签约金额(不含增值税)(元)',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'contractedMoney',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '增值税金额(元)',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'taxRatePrice',
|
||||
valueType: 'text'
|
||||
},
|
||||
{
|
||||
title: '是否中标候选人',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'winnerCandidate',
|
||||
valueType: 'text',
|
||||
valueEnum: {
|
||||
0: {text: '否'},
|
||||
1: {text: '是'},
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '是否通过初步评审',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'firstRvwResult',
|
||||
valueType: 'text',
|
||||
valueEnum: {
|
||||
0: {text: '未通过'},
|
||||
1: {text: '通过'},
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '备注',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
dataIndex: 'remarks',
|
||||
valueType: 'text'
|
||||
},
|
||||
|
||||
]
|
||||
const data: any = [
|
||||
{
|
||||
mingcheng: "ddddd",
|
||||
},
|
||||
{
|
||||
mingcheng: "ssss",
|
||||
}
|
||||
|
||||
]
|
||||
const changeActiveKey=(param:string)=>{
|
||||
console.log(activeKey);
|
||||
const changeActiveKey = (param: string) => {
|
||||
|
||||
let arr=activeKey.concat();
|
||||
let arr = activeKey.concat();
|
||||
|
||||
if(arr.indexOf(param) > -1){
|
||||
if (arr.indexOf(param) > -1) {
|
||||
arr.splice(arr.indexOf(param), 1);
|
||||
} else{
|
||||
} else {
|
||||
arr.push(param);
|
||||
}
|
||||
setActiveKey([...arr]);
|
||||
|
||||
}
|
||||
useEffect(()=>{
|
||||
getBidAssessmentResultsList("1111111").then(res=>{
|
||||
console.log(res)
|
||||
useEffect(() => {
|
||||
/*projectType :2 评标 1 资审*/
|
||||
getBidAssessmentResultsList({"projectId":proID,"projectType":"2"}).then(res => {
|
||||
if (res != undefined && res.message == "success") {
|
||||
setListData(res.data);
|
||||
}else{
|
||||
message.warn("获取信息失败,请稍后")
|
||||
}
|
||||
})
|
||||
},[props.projectId])
|
||||
}, [proID])
|
||||
|
||||
const {Panel} = Collapse;
|
||||
/*推送评标结果*/
|
||||
const pushResult = (record: any) => {
|
||||
pushBidAssessmentResult({
|
||||
"projectId": proID,
|
||||
"sectionId": record.sectionId,
|
||||
}).then(res => {
|
||||
if (res != undefined && res.message == "success") {
|
||||
message.success('推送成功');
|
||||
} else {
|
||||
message.error('推送失败:'+res.message);
|
||||
}
|
||||
})
|
||||
}
|
||||
/*推送列表查看*/
|
||||
const getResultList = (record: any) => {
|
||||
setAssessRoomId(record.assesRoomId);
|
||||
setCurrentTable(true);
|
||||
}
|
||||
|
||||
|
||||
return (
|
||||
<>
|
||||
@ -129,40 +153,79 @@ const BidAssessmentResults: React.FC<BiddingDocumentsDecryptProps> = (props) =>
|
||||
xl: 1,
|
||||
xxl: 1,
|
||||
}}
|
||||
key={Math.random()}
|
||||
itemLayout="vertical"
|
||||
dataSource={[{"pdid": "11"}, {"pdid": "22"}]}
|
||||
dataSource={ListData}
|
||||
renderItem={item => (
|
||||
<List.Item>
|
||||
<List.Item key={Math.random()}>
|
||||
<Card
|
||||
title={"标段名-第几次评审"}
|
||||
title={item.sectionName}
|
||||
extra={
|
||||
<>
|
||||
<Button type="primary"> 推送评标结果 </Button>
|
||||
<Button> 推送列表</Button>
|
||||
<Button onClick={() => changeActiveKey(item.pdid)}> 展开/折叠</Button>
|
||||
<Button onClick={() => changeActiveKey(item.sectionId)}> 展开/折叠</Button>
|
||||
</>
|
||||
}
|
||||
key={Math.random()}
|
||||
>
|
||||
<Collapse
|
||||
activeKey={activeKey}
|
||||
bordered={false}
|
||||
ghost={true}
|
||||
key={Math.random()}
|
||||
>
|
||||
|
||||
<Panel
|
||||
header={""} showArrow={false} key={item.pdid}>
|
||||
<ProTable
|
||||
loading={pageloading}
|
||||
search={false}
|
||||
options={false}
|
||||
columns={columns}
|
||||
dataSource={data}
|
||||
/>
|
||||
header={""} showArrow={false} key={item.sectionId}>
|
||||
<List
|
||||
grid={{
|
||||
gutter: 16,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1,
|
||||
xxl: 1,
|
||||
}}
|
||||
itemLayout="vertical"
|
||||
key={Math.random()}
|
||||
dataSource={item.assesList}
|
||||
renderItem={item1 => (
|
||||
<List.Item key={Math.random()}>
|
||||
<ProTable
|
||||
key={Math.random()}
|
||||
bordered={true}
|
||||
loading={pageloading}
|
||||
search={false}
|
||||
options={false}
|
||||
columns={columns}
|
||||
dataSource={item1.reviewList}
|
||||
toolbar={{
|
||||
title: "第:" + item1.assesRoomSort + "轮",
|
||||
}}
|
||||
rowKey={() => Math.random().toString()}
|
||||
toolBarRender={(record: any) => [
|
||||
<>
|
||||
<Button onClick={() => pushResult(item1)} type="primary"> 推送评标结果 </Button>
|
||||
<Button onClick={() => getResultList(item1)} > 推送列表</Button>
|
||||
</>
|
||||
]}
|
||||
pagination={{
|
||||
pageSizeOptions:['10','20','50'],
|
||||
}}
|
||||
|
||||
/>
|
||||
</List.Item>
|
||||
)}
|
||||
>
|
||||
</List>
|
||||
|
||||
</Panel>
|
||||
</Collapse>
|
||||
</Card>
|
||||
</List.Item>
|
||||
)}
|
||||
/>
|
||||
<CurrentTable assessRoomId={assessRoomId} ChangeNoticeListVisible={currentTable} onCancel={()=>setCurrentTable(false)}/>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
@ -2,11 +2,27 @@ import request from '@/utils/request';
|
||||
// import {demo} from './data.d';
|
||||
|
||||
export async function getBidAssessmentResultsList(params?:any) {
|
||||
alert(params)
|
||||
return request('/api/biz-service-ebtp-calibration/v1/bizbidreviewresult/getSectionAsseslist',{
|
||||
method:'post' ,
|
||||
data:{
|
||||
"projectId":params
|
||||
...params
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
export async function pushBidAssessmentResult(params?:any) {
|
||||
return request('/api/biz-service-ebtp-calibration/v1/bizbidreviewresult/noticeEbpByAssessId',{
|
||||
method:'get' ,
|
||||
data:{
|
||||
...params
|
||||
}
|
||||
})
|
||||
}
|
||||
export async function getBidAssessmentResultList(params?:any) {
|
||||
return request('/api/biz-service-ebtp-calibration/v1/bizinterfacelog/getListByAssessId',{
|
||||
method:'post' ,
|
||||
data:{
|
||||
...params
|
||||
}
|
||||
})
|
||||
}
|
||||
|
Reference in New Issue
Block a user