Commit 0383bb79 authored by 卢均锐's avatar 卢均锐

feat: 采购竞价单审核 列表对接接口

parent 0ff8252b
......@@ -22,7 +22,7 @@ const router = {
{
// 待审核采购竞价单
path: '/purchaseBid/demand/examineSearch',
name: '待审核采购竞价单查询',
name: '待审核采购竞价单',
hidePageHeader: true,
component: '@/pages/purchaseAbility/purchaseBid/examineSearch',
},
......
import React, { useRef,useState } from 'react';
import React, { useRef, useState } from 'react';
import { history, Link } from 'umi';
import { Tag, Typography, Space, Row, Col, Button } from 'antd';
import { ColumnType } from 'antd/lib/table/interface';
......@@ -10,6 +10,8 @@ import { formatTimeString } from '@/utils'
import { PublicApi } from '@/services/api';
import Table from '../../components/table';
import ModalOperate from '../../components/modalOperate';
import {
......@@ -22,6 +24,8 @@ const { Text } = Typography;
const ExamineSearch = () => {
const ref = useRef<any>({});
const [rowkeys, setRowKeys] = useState<Array<number>>([]);
const [id, setId] = useState<any>();
const [visible, setVisible] = useState<boolean>(false);
const columns: ColumnType<any>[] = [{
title: '竞价单号/摘要',
key: 'biddingNo',
......@@ -62,7 +66,12 @@ const ExamineSearch = () => {
key: 'operate',
dataIndex: 'operate',
render: (text: any, record: any) => (
<Link to={`/purchaseBid/demand/examineSearch/detail?id=${record.id}&number=${record.biddingNo}`}>审核</Link>
<Button
type='link'
onClick={() => handleExamine(record.id)}
>
审核
</Button>
)
}];
......@@ -80,6 +89,16 @@ const ExamineSearch = () => {
}
}
const handleExamine = (id: number) => {
setId(id);
setVisible(!visible);
}
const handleSubmit = () => {
setVisible(false);
ref.current.reload();
}
return (
<>
<Table
......@@ -105,6 +124,15 @@ const ExamineSearch = () => {
</Row>
}
/>
<ModalOperate
id={id}
title="单据审核"
modalType="audit"
visible={visible}
fetch={PublicApi.postPurchaseBiddingPlatformExamine}
onOk={() => handleSubmit()}
onCancel={() => setVisible(false)}
/>
</>
)
}
......
......@@ -116,11 +116,10 @@ export const PurchaseBidExamineSearchSchema: ISchema = {
"x-component": "flex-layout",
"x-component-props": {
rowStyle: {
justifyContent: 'flex-start',
flexWrap: 'nowrap'
},
colStyle: {//改变间隔
marginRight: 20
marginLeft: 20
}
},
properties: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment