|
|
@ -11,20 +11,31 @@ import { ApartmentOutlined, TableOutlined } from '@ant-design/icons'; |
|
|
|
import { PinyinHelper, Func as PeaceFunc } from '@peace/utils'; |
|
|
|
import DeviceTree from '../components/device-tree'; |
|
|
|
import { DeviceTypes } from '../constant'; |
|
|
|
import qs from "qs"; |
|
|
|
|
|
|
|
import '../style.less'; |
|
|
|
|
|
|
|
function DeviceMonitor({ ...props }) { |
|
|
|
function DeviceMonitor ({ ...props }) { |
|
|
|
const { |
|
|
|
dispatch, actions, user, clientWidth, clientHeight, loading, |
|
|
|
myStructList, deviceMetasWithFollow, devices, dimensions, deviceListAlarms, factorStations, |
|
|
|
} = props; |
|
|
|
|
|
|
|
|
|
|
|
const [params, setParams] = useState({}); |
|
|
|
const [selectStructure, setSelectStructure] = useState(null); |
|
|
|
const [extraType, setExtraType] = useState('tree'); |
|
|
|
// const pageStyle = Func.getPaginationStyle();
|
|
|
|
|
|
|
|
|
|
|
|
let strucParam = JSON.parse((qs.parse(props.location?.search.slice(1)) || {})?.strucData) |
|
|
|
console.log(1111, strucParam) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
useEffect(() => { |
|
|
|
|
|
|
|
|
|
|
|
// dispatch(actions.dataMonitor.getDeviceMeta());
|
|
|
|
// dispatch(actions.dataMonitor.getMyStructList(user?.orgId)).then((res) => {
|
|
|
|
// if (res.success) {
|
|
|
@ -223,7 +234,7 @@ function DeviceMonitor({ ...props }) { |
|
|
|
success: true, |
|
|
|
}; |
|
|
|
}} |
|
|
|
pagination={{ }} |
|
|
|
pagination={{}} |
|
|
|
options={{ |
|
|
|
search: false, |
|
|
|
reload: false, |
|
|
@ -249,7 +260,7 @@ function DeviceMonitor({ ...props }) { |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|
function mapStateToProps(state) { |
|
|
|
function mapStateToProps (state) { |
|
|
|
const { |
|
|
|
auth, global, myStructList, deviceMeta, deviceList, dimensionsList, deviceListAlarms, factorStations, |
|
|
|
} = state; |
|
|
|