From 1e99f0d8260b8343437015032c4faa113b5124f3 Mon Sep 17 00:00:00 2001
From: vincentlu <t1341870251@gmail.com>
Date: 星期三, 17 十二月 2025 13:40:31 +0800
Subject: [PATCH] #
---
zy-acs-flow/src/map/MapPage.jsx | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/zy-acs-flow/src/map/MapPage.jsx b/zy-acs-flow/src/map/MapPage.jsx
index 610badc..0de9c8a 100644
--- a/zy-acs-flow/src/map/MapPage.jsx
+++ b/zy-acs-flow/src/map/MapPage.jsx
@@ -14,6 +14,7 @@
import { NotificationProvider, useNotification } from './Notification';
import Insight from "./insight";
import Device from "./Device";
+import AreaList from "./AreaList";
import Settings from "./settings";
import Batch from "./batch";
import AreaSettings from "./areaSettings";
@@ -52,6 +53,7 @@
const [settingsVisible, setSettingsVisible] = useState(false);
const [batchSelectionVisible, setBatchSelectionVisible] = useState(false);
const [areaSettingsVisible, setAreaSettingsVisible] = useState(false);
+ const [areaListVisible, setAreaListVisible] = useState(false);
const [areaDrawing, setAreaDrawing] = useState(false);
const [curSprite, setCurSprite] = useState(null);
@@ -139,6 +141,7 @@
setBatchSelectionVisible(false);
setAreaSettingsVisible(false);
setAreaDrawing(false);
+ setAreaListVisible(false);
Tool.cancelAreaDrawing();
Tool.hideAreas(curZone, setShowAreas);
@@ -365,6 +368,13 @@
{mode === MAP_MODE.AREA_MODE && (
<>
<Button
+ variant="outlined"
+ onClick={() => setAreaListVisible(!areaListVisible)}
+ sx={{ mr: 2 }}
+ >
+ {translate('page.map.action.areaList')}
+ </Button>
+ <Button
variant={areaDrawing ? "outlined" : "contained"}
color="primary"
sx={{}}
@@ -562,6 +572,15 @@
width={570}
/>
+ <AreaList
+ open={areaListVisible}
+ onCancel={() => {
+ setAreaListVisible(false);
+ }}
+ onDrop={onDrop}
+ width={400}
+ />
+
</Box>
);
}
--
Gitblit v1.9.1