页面列表与按钮样式 调整
This commit is contained in:
@ -1,9 +1,14 @@
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { Table, Form, Select, Button, Tag, message, Space } from 'antd';
|
||||
import { SearchOutlined, ReloadOutlined } from '@ant-design/icons';
|
||||
import { getApprovePage } from './services';
|
||||
import { Table, Form, Select, Button, message, Space } from 'antd';
|
||||
import { SearchOutlined, DeleteOutlined } from '@ant-design/icons';
|
||||
import type { ColumnsType } from 'antd/es/table';
|
||||
//接口
|
||||
import { getApprovePage } from './services';
|
||||
//组件
|
||||
import ViewModal from './components/ViewModal';
|
||||
//统一列表分页
|
||||
import tableProps from '@/utils/tableProps'
|
||||
|
||||
const { Option } = Select;
|
||||
interface SupplierEntryReviewRecord {
|
||||
id: string;
|
||||
@ -106,7 +111,7 @@ const SupplierEntryReview: React.FC = () => {
|
||||
{
|
||||
title: '序号',
|
||||
dataIndex: 'index',
|
||||
width: 48,
|
||||
width: 60,
|
||||
align: 'center',
|
||||
render: (_: any, __: any, idx: number) => (((pagination.current ?? 1) - 1) * (pagination.pageSize ?? 10)) + idx + 1,
|
||||
},
|
||||
@ -134,7 +139,7 @@ const SupplierEntryReview: React.FC = () => {
|
||||
render: (_: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
{record.categoryNameList && record.categoryNameList.map((item:string) => {
|
||||
{record.categoryNameList && record.categoryNameList.map((item: string) => {
|
||||
return <div>{`${item}`}</div>
|
||||
})}
|
||||
</>
|
||||
@ -143,15 +148,17 @@ const SupplierEntryReview: React.FC = () => {
|
||||
},
|
||||
{
|
||||
title: '开始时间',
|
||||
dataIndex: 'startTime',
|
||||
dataIndex: 'createTime',
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
width: 180,
|
||||
},
|
||||
{
|
||||
title: '结束时间',
|
||||
dataIndex: 'endTime',
|
||||
dataIndex: 'lastUpdateTime',
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
width: 180,
|
||||
},
|
||||
{
|
||||
title: '流程状态',
|
||||
@ -177,55 +184,55 @@ const SupplierEntryReview: React.FC = () => {
|
||||
},
|
||||
];
|
||||
return (
|
||||
<div>
|
||||
<Form
|
||||
form={form}
|
||||
layout="inline"
|
||||
style={{ marginBottom: 16 }}
|
||||
onFinish={handleSearch}
|
||||
>
|
||||
<Form.Item name="accessType" label="准入方式">
|
||||
<Select style={{ width: 150 }} placeholder="请选择准入方式" allowClear >
|
||||
<Option value="online">线上准入</Option>
|
||||
<Option value="offline">线下准入</Option>
|
||||
<Option value="scattered">零星采购/应急采购/个人供应商</Option>
|
||||
</Select>
|
||||
</Form.Item>
|
||||
<Form.Item name="deptId" label="准入部门">
|
||||
<Select options={deptOptions} allowClear style={{ width: 120 }} placeholder="请选择准入部门" />
|
||||
</Form.Item>
|
||||
<div className="common-container">
|
||||
<div className="filter-action-row">
|
||||
<Form
|
||||
form={form}
|
||||
layout="inline"
|
||||
className="filter-form"
|
||||
onFinish={handleSearch}
|
||||
>
|
||||
<Form.Item name="accessType" label="准入方式">
|
||||
<Select style={{ width: 150 }} placeholder="请选择准入方式" allowClear >
|
||||
<Option value="online">线上准入</Option>
|
||||
<Option value="offline">线下准入</Option>
|
||||
<Option value="scattered">零星采购/应急采购/个人供应商</Option>
|
||||
</Select>
|
||||
</Form.Item>
|
||||
<Form.Item name="deptId" label="准入部门">
|
||||
<Select options={deptOptions} allowClear style={{ width: 120 }} placeholder="请选择准入部门" />
|
||||
</Form.Item>
|
||||
|
||||
<Form.Item name="approveStatus" label="流程状态">
|
||||
<Select style={{ width: 150 }} placeholder="请选择状态" allowClear>
|
||||
<Option value="0">未开始</Option>
|
||||
<Option value="1">进行中</Option>
|
||||
<Option value="2">结果汇总中</Option>
|
||||
<Option value="3">已完成</Option>
|
||||
</Select>
|
||||
</Form.Item>
|
||||
<Form.Item>
|
||||
<Button type="primary" htmlType="submit" icon={<SearchOutlined />} style={{ marginRight: 8 }}>
|
||||
查询
|
||||
</Button>
|
||||
<Button onClick={handleReset} icon={<ReloadOutlined />}>
|
||||
重置
|
||||
</Button>
|
||||
</Form.Item>
|
||||
</Form>
|
||||
<Form.Item name="approveStatus" label="流程状态">
|
||||
<Select style={{ width: 150 }} placeholder="请选择状态" allowClear>
|
||||
<Option value="0">未开始</Option>
|
||||
<Option value="1">进行中</Option>
|
||||
<Option value="2">结果汇总中</Option>
|
||||
<Option value="3">已完成</Option>
|
||||
</Select>
|
||||
</Form.Item>
|
||||
|
||||
<Form.Item>
|
||||
<Button className="buttonSubmit" type="primary" htmlType="submit" icon={<SearchOutlined />} >
|
||||
搜索
|
||||
</Button>
|
||||
</Form.Item>
|
||||
<Form.Item>
|
||||
<Button className="buttonReset" icon={<DeleteOutlined />} onClick={handleReset} >重置</Button>
|
||||
</Form.Item>
|
||||
|
||||
|
||||
</Form>
|
||||
</div>
|
||||
<Table
|
||||
columns={columns}
|
||||
dataSource={data}
|
||||
rowKey="id"
|
||||
loading={loading}
|
||||
pagination={{
|
||||
current: pagination.current,
|
||||
pageSize: pagination.pageSize,
|
||||
total: pagination.total,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
}}
|
||||
pagination={{ ...tableProps.pagination, total: pagination.total }}
|
||||
onChange={handleTableChange}
|
||||
style={{ flex: 1, minHeight: 0 }}
|
||||
scroll={{ y: 'calc(100vh - 350px)' }}
|
||||
/>
|
||||
<ViewModal
|
||||
visible={modalInfo.visible}
|
||||
|
Reference in New Issue
Block a user