From bbe325f4602ce66c08d6280b75f895778232d1c4 Mon Sep 17 00:00:00 2001
From: vincentlu <t1341870251@gmail.com>
Date: 星期五, 12 十二月 2025 11:10:33 +0800
Subject: [PATCH] #

---
 zy-acs-flow/src/map/tool.js |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/zy-acs-flow/src/map/tool.js b/zy-acs-flow/src/map/tool.js
index 3ebb75d..fcb761d 100644
--- a/zy-acs-flow/src/map/tool.js
+++ b/zy-acs-flow/src/map/tool.js
@@ -903,14 +903,14 @@
     fetchAreaList(curZone).then((areas) => {
         areas.forEach((area) => {
             const { name, color, id } = area || {};
-            const start = area?.start || (area?.startX != null ? { x: area.startX, y: area.startY } : null);
-            const end = area?.end || (area?.endX != null ? { x: area.endX, y: area.endY } : null);
-            if (!start || !end || !name) {
+            const start = area?.start;
+            const end = area?.end;
+            if (!start || !end || !name || !id) {
                 return;
             }
-            const g = createAreaGraphic({ name, start, end, color, id });
-            if (g) {
-                mapContainer.addChild(g);
+            const graphics = createAreaGraphic({ name, start, end, color, id });
+            if (graphics) {
+                mapContainer.addChild(graphics);
             }
         });
     });

--
Gitblit v1.9.1