|
|
|
|
@ -1,10 +1,10 @@
|
|
|
|
|
import React, { useState, useEffect } from 'react';
|
|
|
|
|
import { Input, Button, Select, message, Modal } from 'antd';
|
|
|
|
|
import { Input, Button, Select, message, Modal, DatePicker } from 'antd';
|
|
|
|
|
import { SearchOutlined, PlusOutlined, DeleteOutlined, EditOutlined } from '@ant-design/icons';
|
|
|
|
|
import StandardTable from '@/components/StandardTable';
|
|
|
|
|
import styles from './jjjl.less';
|
|
|
|
|
|
|
|
|
|
import iconsc from '@/assets/yjzygl/iconsc.svg';
|
|
|
|
|
import iconDrill5 from '@/assets/business_Emergency/iconDrill5.svg';
|
|
|
|
|
|
|
|
|
|
const { Option } = Select;
|
|
|
|
|
|
|
|
|
|
@ -12,6 +12,7 @@ const Jjjl = () => {
|
|
|
|
|
const [loading, setLoading] = useState(false);
|
|
|
|
|
const [selectedRowKeys, setSelectedRowKeys] = useState([]);
|
|
|
|
|
const [searchValue, setSearchValue] = useState(undefined);
|
|
|
|
|
const [dateRange, setDateRange] = useState([null, null]);
|
|
|
|
|
const [pagination, setPagination] = useState({
|
|
|
|
|
current: 1,
|
|
|
|
|
pageSize: 10,
|
|
|
|
|
@ -159,8 +160,8 @@ const Jjjl = () => {
|
|
|
|
|
key: 'fireImage',
|
|
|
|
|
width: 120,
|
|
|
|
|
render: (text) => (
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
size="small"
|
|
|
|
|
onClick={() => message.info('查看图片功能待实现')}
|
|
|
|
|
>
|
|
|
|
|
@ -180,17 +181,17 @@ const Jjjl = () => {
|
|
|
|
|
width: 120,
|
|
|
|
|
render: (text, record) => (
|
|
|
|
|
<div className={styles.actionButtons}>
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
size="small"
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
size="small"
|
|
|
|
|
// icon={<EditOutlined />}
|
|
|
|
|
onClick={() => handleEdit(record)}
|
|
|
|
|
>
|
|
|
|
|
修改
|
|
|
|
|
</Button>
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
size="small"
|
|
|
|
|
<Button
|
|
|
|
|
type="link"
|
|
|
|
|
size="small"
|
|
|
|
|
danger
|
|
|
|
|
// icon={<DeleteOutlined />}
|
|
|
|
|
onClick={() => handleDelete(record)}
|
|
|
|
|
@ -266,12 +267,52 @@ const Jjjl = () => {
|
|
|
|
|
|
|
|
|
|
{/* 搜索和操作区域 */}
|
|
|
|
|
<div className={styles.searchBar}>
|
|
|
|
|
|
|
|
|
|
<div className={styles.searchItem}>
|
|
|
|
|
|
|
|
|
|
<span className={styles.searchLabel}>时间范围:</span>
|
|
|
|
|
<div style={{ display: 'flex', alignItems: 'center', border: '1px solid #DDDEE6', borderRadius: '2px' }}>
|
|
|
|
|
<div className={styles.datePickerWithIcon}>
|
|
|
|
|
<img src={iconDrill5} alt="日期icon" className={styles.dateIcon} />
|
|
|
|
|
<DatePicker
|
|
|
|
|
showTime={{ format: 'HH:mm' }}
|
|
|
|
|
format="YYYY-MM-DD HH:mm"
|
|
|
|
|
value={dateRange ? dateRange[0] : null}
|
|
|
|
|
onChange={(value) => {
|
|
|
|
|
setDateRange([value, dateRange ? dateRange[1] : null]);
|
|
|
|
|
}}
|
|
|
|
|
placeholder="请输入演练日期"
|
|
|
|
|
className={styles.datePickerFirst}
|
|
|
|
|
suffixIcon={null}
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
{/* 短线 */}
|
|
|
|
|
<div className={styles.dateSeparator}></div>
|
|
|
|
|
|
|
|
|
|
<div className={styles.datePickerWithIcon}>
|
|
|
|
|
<img src={iconDrill5} alt="日期icon" className={styles.dateIcon} />
|
|
|
|
|
<DatePicker
|
|
|
|
|
showTime={{ format: 'HH:mm' }}
|
|
|
|
|
format="YYYY-MM-DD HH:mm"
|
|
|
|
|
value={dateRange ? dateRange[1] : null}
|
|
|
|
|
onChange={(value) => {
|
|
|
|
|
setDateRange([dateRange ? dateRange[0] : null, value]);
|
|
|
|
|
}}
|
|
|
|
|
placeholder="请输入演练日期"
|
|
|
|
|
className={styles.datePickerFirst}
|
|
|
|
|
suffixIcon={null}
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div className={styles.searchLeft}>
|
|
|
|
|
<Select
|
|
|
|
|
placeholder="请选择消防点"
|
|
|
|
|
value={searchValue}
|
|
|
|
|
onChange={setSearchValue}
|
|
|
|
|
style={{width: 180}}
|
|
|
|
|
style={{ width: 180 }}
|
|
|
|
|
className={styles.customSelect}
|
|
|
|
|
allowClear
|
|
|
|
|
>
|
|
|
|
|
@ -284,12 +325,12 @@ const Jjjl = () => {
|
|
|
|
|
</Select>
|
|
|
|
|
<Input
|
|
|
|
|
placeholder="请输入消防点名称"
|
|
|
|
|
style={{width: 180}}
|
|
|
|
|
style={{ width: 180 }}
|
|
|
|
|
className={styles.customInput}
|
|
|
|
|
allowClear
|
|
|
|
|
/>
|
|
|
|
|
<Button
|
|
|
|
|
type="primary"
|
|
|
|
|
<Button
|
|
|
|
|
type="primary"
|
|
|
|
|
icon={<SearchOutlined />}
|
|
|
|
|
onClick={handleSearch}
|
|
|
|
|
loading={loading}
|
|
|
|
|
@ -299,8 +340,8 @@ const Jjjl = () => {
|
|
|
|
|
</Button>
|
|
|
|
|
</div>
|
|
|
|
|
<div className={styles.searchRight}>
|
|
|
|
|
<Button
|
|
|
|
|
type="primary"
|
|
|
|
|
<Button
|
|
|
|
|
type="primary"
|
|
|
|
|
icon={<PlusOutlined />}
|
|
|
|
|
onClick={handleAdd}
|
|
|
|
|
className={styles.customButton}
|
|
|
|
|
|