diff --git a/src/pages/business_emergencyResource/components/EmergencyRescue.js b/src/pages/business_emergencyResource/components/EmergencyRescue.js
index 2fb2045..5bdcbdf 100644
--- a/src/pages/business_emergencyResource/components/EmergencyRescue.js
+++ b/src/pages/business_emergencyResource/components/EmergencyRescue.js
@@ -1,15 +1,47 @@
-import React from 'react';
-import { Card } from 'antd';
+import React, { useState } from 'react';
import styles from './EmergencyRescue.less';
+import Jjjl from './secondary_menu/jjjl';
+import Czjy from './secondary_menu/czjy';
const EmergencyRescue = () => {
+ const [activeButton, setActiveButton] = useState('接警记录');
+
+ const handleButtonClick = (buttonName) => {
+ setActiveButton(buttonName);
+ };
+
+ const buttonList = [
+ '接警记录',
+ '处置救援'
+ ];
+
+ const renderContent = () => {
+ switch (activeButton) {
+ case '接警记录':
+ return ;
+ case '处置救援':
+ return ;
+ default:
+ return ;
+ }
+ };
+
return (
-
-
- 救援
-
-
+
+ {buttonList.map((buttonName) => (
+
handleButtonClick(buttonName)}
+ >
+ {buttonName}
+
+ ))}
+
+
+ {renderContent()}
+
);
};
diff --git a/src/pages/business_emergencyResource/components/EmergencyRescue.less b/src/pages/business_emergencyResource/components/EmergencyRescue.less
index 163500c..f4e6e40 100644
--- a/src/pages/business_emergencyResource/components/EmergencyRescue.less
+++ b/src/pages/business_emergencyResource/components/EmergencyRescue.less
@@ -1,3 +1,44 @@
.container {
- padding: 20px;
+ background-color: transparent;
+ min-height: 100vh;
+ display: flex;
+ flex-direction: column;
+}
+
+.buttonRow {
+ display: flex;
+ gap: 16px;
+ flex-wrap: wrap;
+ margin-top: 10px;
+ margin-left: 5px;
+ padding: 10px 20px 10px 30px;
+ background-color: #EBF0FE;
+}
+
+.button {
+ background-color: transparent;
+ color: #333333;
+ font-size: 13px;
+ font-weight: 500;
+ padding: 8px 16px;
+ border-radius: 6px;
+ cursor: pointer;
+ transition: all 0.3s ease;
+ border: 1px solid transparent;
+
+ &:hover {
+ background-color: rgba(46, 76, 212, 0.1);
+ }
+
+ &.active {
+ color: #fff;
+ background: linear-gradient(180deg, #556FEB 0%, #8DAAF7 100%);
+ }
+}
+
+.contentArea {
+ flex: 1;
+ background-color: #EBF0FE;
+ margin-left: 5px;
+ // margin-top: 10px;
}
diff --git a/src/pages/business_emergencyResource/components/secondary_menu/yjxf.js b/src/pages/business_emergencyResource/components/secondary_menu/czjy.js
similarity index 50%
rename from src/pages/business_emergencyResource/components/secondary_menu/yjxf.js
rename to src/pages/business_emergencyResource/components/secondary_menu/czjy.js
index 134ae07..7fae224 100644
--- a/src/pages/business_emergencyResource/components/secondary_menu/yjxf.js
+++ b/src/pages/business_emergencyResource/components/secondary_menu/czjy.js
@@ -1,89 +1,28 @@
-import React, { useState, useEffect } from 'react';
-import { Input, Button, Select, message, Modal } from 'antd';
-import { SearchOutlined, PlusOutlined, DeleteOutlined, EditOutlined } from '@ant-design/icons';
+import React, { useState } from 'react';
+import { Input, Button, Select, message } from 'antd';
+import { SearchOutlined, PlusOutlined } from '@ant-design/icons';
import StandardTable from '@/components/StandardTable';
-import styles from './yjzbry.less';
+import styles from './czjy.less';
import iconsc from '@/assets/yjzygl/iconsc.svg';
const { Option } = Select;
-const Yjxf = () => {
+const Czjy = () => {
const [loading, setLoading] = useState(false);
const [selectedRowKeys, setSelectedRowKeys] = useState([]);
const [searchValue, setSearchValue] = useState('');
const [pagination, setPagination] = useState({
current: 1,
pageSize: 10,
- total: 48,
+ total: 0,
showSizeChanger: true,
showQuickJumper: true,
showTotal: (total, range) => `共${total}条`,
});
- // 模拟数据
- const [dataSource, setDataSource] = useState([
- {
- key: '1',
- number: '01',
- unitName: '文登市兴文新材料有限公司',
- name: '国云海',
- position: '生产班长',
- mobile: '17898786567',
- email: '1878967633@qq.com',
- dutyTime: '夜班',
- },
- {
- key: '2',
- number: '02',
- unitName: '文登市兴文新材料有限公司',
- name: '陈志强',
- position: '生产班长',
- mobile: '17898786567',
- email: '1878967633@qq.com',
- dutyTime: '白班',
- },
- {
- key: '3',
- number: '03',
- unitName: '合湾新材科技有限公司',
- name: '侯文涛',
- position: '班长',
- mobile: '17898786567',
- email: '1878967633@qq.com',
- dutyTime: '白班',
- },
- {
- key: '4',
- number: '04',
- unitName: '山东万图高分子材料股份有限公司',
- name: '宋东',
- position: '班长',
- mobile: '17898786567',
- email: '1878967633@qq.com',
- dutyTime: '夜班',
- },
- {
- key: '5',
- number: '05',
- unitName: '合鸿新材科技有限公司',
- name: '王一声',
- position: '班长',
- mobile: '17898786567',
- email: '1878967633@qq.com',
- dutyTime: '夜班',
- },
- {
- key: '6',
- number: '06',
- unitName: '山东万图高分子材料股份有限公司',
- name: '赵小敏',
- position: '班长',
- mobile: '17898786567',
- email: '1878987633@qq.com',
- dutyTime: '夜班',
- },
- ]);
+ // 数据源
+ const [dataSource, setDataSource] = useState([]);
// 表格列配置
const columns = [
@@ -93,42 +32,6 @@ const Yjxf = () => {
key: 'number',
width: 80,
},
- {
- title: '单位名称',
- dataIndex: 'unitName',
- key: 'unitName',
- width: 200,
- },
- {
- title: '姓名',
- dataIndex: 'name',
- key: 'name',
- width: 100,
- },
- {
- title: '职务',
- dataIndex: 'position',
- key: 'position',
- width: 120,
- },
- {
- title: '手机号',
- dataIndex: 'mobile',
- key: 'mobile',
- width: 130,
- },
- {
- title: '邮箱',
- dataIndex: 'email',
- key: 'email',
- width: 180,
- },
- {
- title: '值班时间',
- dataIndex: 'dutyTime',
- key: 'dutyTime',
- width: 100,
- },
{
title: '操作',
key: 'action',
@@ -138,7 +41,6 @@ const Yjxf = () => {
}
onClick={() => handleEdit(record)}
>
修改
@@ -147,7 +49,6 @@ const Yjxf = () => {
type="link"
size="small"
danger
- // icon={}
onClick={() => handleDelete(record)}
>
删除
@@ -160,7 +61,6 @@ const Yjxf = () => {
// 搜索处理
const handleSearch = () => {
setLoading(true);
- // 模拟搜索请求
setTimeout(() => {
setLoading(false);
message.success('查询完成');
@@ -169,7 +69,7 @@ const Yjxf = () => {
// 新增处理
const handleAdd = () => {
- message.info('新增功能待实现');
+ message.info('新增功能待开发');
};
// 批量删除处理
@@ -178,32 +78,17 @@ const Yjxf = () => {
message.warning('请选择要删除的数据');
return;
}
- Modal.confirm({
- title: '确认删除',
- content: `确定要删除选中的 ${selectedRowKeys.length} 条数据吗?`,
- onOk() {
- setDataSource(dataSource.filter(item => !selectedRowKeys.includes(item.key)));
- setSelectedRowKeys([]);
- message.success('删除成功');
- },
- });
+ message.info('删除功能待开发');
};
// 编辑处理
const handleEdit = (record) => {
- message.info(`编辑 ${record.name} 的信息`);
+ message.info('编辑功能待开发');
};
// 删除处理
const handleDelete = (record) => {
- Modal.confirm({
- title: '确认删除',
- content: `确定要删除 ${record.name} 吗?`,
- onOk() {
- setDataSource(dataSource.filter(item => item.key !== record.key));
- message.success('删除成功');
- },
- });
+ message.info('删除功能待开发');
};
// 分页处理
@@ -216,23 +101,21 @@ const Yjxf = () => {
{/* 页面标题 */}
{/* 搜索和操作区域 */}