From c05ee091c5e3f3086260c8c53538a5ea007d1a6a Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@163.com>
Date: 星期四, 14 三月 2024 16:13:56 +0800
Subject: [PATCH] #
---
zy-asrs-flow/src/pages/map/header/search.jsx | 25 +++++++++----------------
1 files changed, 9 insertions(+), 16 deletions(-)
diff --git a/zy-asrs-flow/src/pages/map/header/search.jsx b/zy-asrs-flow/src/pages/map/header/search.jsx
index 5036689..6ad51bf 100644
--- a/zy-asrs-flow/src/pages/map/header/search.jsx
+++ b/zy-asrs-flow/src/pages/map/header/search.jsx
@@ -48,22 +48,15 @@
return
}
setSensorList([]);
- switch (curSensorType) {
- case Utils.SENSOR_TYPE.SHELF:
- Utils.getMapContainer().children.forEach(child => {
- if (child?.data?.type === Utils.SENSOR_TYPE.SHELF && child?.data?.no) {
- setSensorList(prevArr => [...prevArr, {
- value: child.data.no,
- label: renderTitle(child.data.no, child.data.uuid)
- }]);
- }
- })
- break;
- case Utils.SENSOR_TYPE.AGV:
- break;
- default:
- break;
- }
+ setCurSensorLabel(null);
+ Utils.getMapContainer().children.forEach(child => {
+ if (child?.data?.type === curSensorType && child?.data?.no) {
+ setSensorList(prevArr => [...prevArr, {
+ value: child.data.no,
+ label: renderTitle(child.data.no, child.data.uuid)
+ }]);
+ }
+ });
}, [curSensorType])
return (
--
Gitblit v1.9.1