From 2ec11cf252a1d9ba5aea1c1b32615237ea3603b1 Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@163.com>
Date: 星期日, 03 三月 2024 16:18:05 +0800
Subject: [PATCH] #

---
 zy-asrs-flow/src/pages/map/utils.js |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/zy-asrs-flow/src/pages/map/utils.js b/zy-asrs-flow/src/pages/map/utils.js
index dd542bd..88cf1e3 100644
--- a/zy-asrs-flow/src/pages/map/utils.js
+++ b/zy-asrs-flow/src/pages/map/utils.js
@@ -12,10 +12,10 @@
     mapContainer = param;
 }
 
-export const getRealPosition = (x, y) => {
+export const getRealPosition = (x, y, scale) => {
     const rect = app.view.getBoundingClientRect();
     return {
-        mapX: x - rect.left,
-        mapY: y - rect.top
+        mapX: (x - rect.left) / scale,
+        mapY: (y - rect.top) / scale
     }
 }
\ No newline at end of file

--
Gitblit v1.9.1