|
|
|
@ -2,7 +2,7 @@
|
|
|
|
|
* @Author: donghao donghao@supervision.ltd
|
|
|
|
|
* @Date: 2024-05-10 10:47:45
|
|
|
|
|
* @LastEditors: donghao donghao@supervision.ltd
|
|
|
|
|
* @LastEditTime: 2024-06-25 10:06:05
|
|
|
|
|
* @LastEditTime: 2024-07-22 15:17:48
|
|
|
|
|
* @FilePath: \general-ai-platform-web\src\pages\Business\BusinessState\deviceSate.tsx
|
|
|
|
|
* @Description: 设备状态列表
|
|
|
|
|
* @交互说明
|
|
|
|
@ -31,7 +31,7 @@ import {
|
|
|
|
|
import { FormattedMessage, useIntl } from '@umijs/max';
|
|
|
|
|
import { Tabs } from 'antd';
|
|
|
|
|
import { useEffect, useState } from 'react';
|
|
|
|
|
import { proTablePaginationOptions } from '../../../../config/defaultTable';
|
|
|
|
|
import { proTableDefaultOptions, proTablePaginationOptions } from '../../../../config/defaultTable';
|
|
|
|
|
import DetailDeviceState from './components/detailDeviceState';
|
|
|
|
|
import DeviceStateCard from './components/deviceStateCard';
|
|
|
|
|
import './index.less';
|
|
|
|
@ -196,9 +196,7 @@ const DeviceSate: React.FC = () => {
|
|
|
|
|
item.label = `${deviceStateEnums[2].label}(${currCounts[deviceStateEnums[2].key]})`;
|
|
|
|
|
break;
|
|
|
|
|
case '1003':
|
|
|
|
|
item.label = `${deviceStateEnums[3].label}(${
|
|
|
|
|
currCounts[deviceStateEnums[3].key]
|
|
|
|
|
}})`;
|
|
|
|
|
item.label = `${deviceStateEnums[3].label}(${currCounts[deviceStateEnums[3].key]})`;
|
|
|
|
|
break;
|
|
|
|
|
case '1004':
|
|
|
|
|
item.label = `${deviceStateEnums[4].label}(${currCounts[deviceStateEnums[4].key]})`;
|
|
|
|
@ -356,6 +354,7 @@ const DeviceSate: React.FC = () => {
|
|
|
|
|
></Tabs>
|
|
|
|
|
<div className="gn_scroll_list_wrap" style={{ height: 'calc(100vh - 240px)' }}>
|
|
|
|
|
<ProList<any>
|
|
|
|
|
{...proTableDefaultOptions}
|
|
|
|
|
className="gn_pro_list"
|
|
|
|
|
ghost={true}
|
|
|
|
|
rowKey={'id'}
|
|
|
|
@ -369,16 +368,20 @@ const DeviceSate: React.FC = () => {
|
|
|
|
|
margin: '-4px 0',
|
|
|
|
|
},
|
|
|
|
|
}}
|
|
|
|
|
pagination={{
|
|
|
|
|
...proTablePaginationOptions,
|
|
|
|
|
pageNo: currentPage,
|
|
|
|
|
pageSize: currentPageSize,
|
|
|
|
|
total: total || 0, // 指定总条目数
|
|
|
|
|
onChange: (pageNo, pageSize) => {
|
|
|
|
|
setCurrentPageSize(pageSize);
|
|
|
|
|
setCurrentPage(pageNo);
|
|
|
|
|
},
|
|
|
|
|
}}
|
|
|
|
|
pagination={
|
|
|
|
|
serverList.length
|
|
|
|
|
? {
|
|
|
|
|
...proTablePaginationOptions,
|
|
|
|
|
pageNo: currentPage,
|
|
|
|
|
pageSize: currentPageSize,
|
|
|
|
|
total: total || 0, // 指定总条目数
|
|
|
|
|
onChange: (pageNo, pageSize) => {
|
|
|
|
|
setCurrentPageSize(pageSize);
|
|
|
|
|
setCurrentPage(pageNo);
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
: false
|
|
|
|
|
}
|
|
|
|
|
rowSelection={false}
|
|
|
|
|
grid={{ gutter: 16, xs: 1, md: 2, lg: 3, xl: 4, xxl: 5 }}
|
|
|
|
|
metas={{
|
|
|
|
|