12-23-上传master
This commit is contained in:
195
src/pages/Calibration/Supplier/ViewNotice/index.tsx
Normal file
195
src/pages/Calibration/Supplier/ViewNotice/index.tsx
Normal file
@ -0,0 +1,195 @@
|
||||
import React, {useEffect, useState} from 'react';
|
||||
import {Button, Card, Collapse, Divider, List,Modal} from "antd";
|
||||
import ProTable from "@ant-design/pro-table";
|
||||
import {getBidAssessmentResultsList} from "./service"
|
||||
|
||||
interface ResultNoticeProps {
|
||||
projectId: "1331563848498413568";/*?项目id*/
|
||||
}
|
||||
|
||||
const ResultNotice: React.FC<ResultNoticeProps> = (props) => {
|
||||
const [pageloading, setPageloading] = useState<boolean>(false);
|
||||
const [ListData, setListData] = useState<any>();
|
||||
|
||||
const [zbtzsFormVisible, setZbtzsFormVisible] = useState<any>(false);
|
||||
const [jgtzsFormVisible, setJgtzsFormVisible] = useState<any>(false);
|
||||
const [activeKey, setActiveKey] = useState<any>([]);
|
||||
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
title: '排名',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '应答人',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '通知书类别',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '价格',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '状态',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '中选服务费通知书',
|
||||
dataIndex: 'mingcheng',
|
||||
valueType: 'index'
|
||||
},
|
||||
{
|
||||
title: '备注',
|
||||
dataIndex: 'xuhao',
|
||||
valueType: 'index'
|
||||
},{
|
||||
title: '操作',
|
||||
dataIndex: 'option',
|
||||
width: 180,
|
||||
valueType: 'option',
|
||||
render: (_: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
<Button size='small' type="primary" onClick={() => { }}>编辑结果通知书</Button>
|
||||
<Button size='small' type="primary" onClick={() => { }}>编辑中标通知书</Button>
|
||||
</>
|
||||
)
|
||||
}
|
||||
},
|
||||
|
||||
]
|
||||
const data: any = [
|
||||
{
|
||||
mingcheng: "ddddd",
|
||||
},
|
||||
{
|
||||
mingcheng: "ssss",
|
||||
}
|
||||
|
||||
]
|
||||
const changeActiveKey=(param:string)=>{
|
||||
console.log(activeKey);
|
||||
|
||||
let arr=activeKey.concat();
|
||||
|
||||
if(arr.indexOf(param) > -1){
|
||||
arr.splice(arr.indexOf(param), 1);
|
||||
} else{
|
||||
arr.push(param);
|
||||
}
|
||||
setActiveKey([...arr]);
|
||||
|
||||
}
|
||||
useEffect(() => {
|
||||
getBidAssessmentResultsList("1111111").then(res => {
|
||||
if (res != undefined && res.message == "success"){
|
||||
setListData(res.data);
|
||||
}
|
||||
})
|
||||
}, [props.projectId])
|
||||
|
||||
const {Panel} = Collapse;
|
||||
|
||||
return (
|
||||
<>
|
||||
<List
|
||||
grid={{
|
||||
gutter: 16,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1,
|
||||
xxl: 1,
|
||||
}}
|
||||
itemLayout="vertical"
|
||||
dataSource={ListData}
|
||||
renderItem={item => (
|
||||
<List.Item>
|
||||
<Card
|
||||
title={item.sectionName}
|
||||
extra={
|
||||
<>
|
||||
<Button onClick={() => changeActiveKey(item.sectionId)}> 展开/折叠</Button>
|
||||
</>
|
||||
}
|
||||
>
|
||||
<Collapse
|
||||
activeKey={activeKey}
|
||||
bordered={false}
|
||||
ghost={true}
|
||||
>
|
||||
<Panel
|
||||
header={""} showArrow={false} key={item.sectionId}>
|
||||
<List
|
||||
grid={{
|
||||
gutter: 16,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1,
|
||||
xxl: 1,
|
||||
}}
|
||||
itemLayout="vertical"
|
||||
dataSource={item.assesList}
|
||||
renderItem={item1 => (
|
||||
<List.Item>
|
||||
<ProTable
|
||||
bordered={true}
|
||||
loading={pageloading}
|
||||
search={false}
|
||||
options={false}
|
||||
columns={columns}
|
||||
dataSource={item1.reviewList}
|
||||
toolbar={{
|
||||
title: "第:"+item1.sectionId+"轮",
|
||||
}}
|
||||
toolBarRender={() => [
|
||||
<>
|
||||
<Button type="primary"> 定标结束 </Button>
|
||||
<Button> 发送中选通知书</Button>
|
||||
<Button> 发送服务费通知书</Button>
|
||||
</>
|
||||
]}
|
||||
/>
|
||||
</List.Item>
|
||||
)}
|
||||
>
|
||||
</List>
|
||||
</Panel>
|
||||
</Collapse>
|
||||
</Card>
|
||||
</List.Item>
|
||||
|
||||
)}
|
||||
/>
|
||||
<Modal
|
||||
destroyOnClose
|
||||
title={"编辑中标通知书"}
|
||||
visible={zbtzsFormVisible}
|
||||
onCancel={() => {
|
||||
setZbtzsFormVisible(false)
|
||||
}}
|
||||
onOk={() => {
|
||||
setZbtzsFormVisible(false)
|
||||
}}
|
||||
okText="保存"
|
||||
cancelText="取消"
|
||||
width={800}
|
||||
>
|
||||
|
||||
</Modal>
|
||||
</>
|
||||
)
|
||||
}
|
||||
export default ResultNotice
|
12
src/pages/Calibration/Supplier/ViewNotice/service.ts
Normal file
12
src/pages/Calibration/Supplier/ViewNotice/service.ts
Normal file
@ -0,0 +1,12 @@
|
||||
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
|
||||
}
|
||||
})
|
||||
}
|
Reference in New Issue
Block a user