Przeglądaj źródła

fix: 取消选中基准点

jinx 2 lat temu
rodzic
commit
122ab3e5b1

Plik diff jest za duży
+ 1 - 1
server/test/a0k4xu045_202305311600080410/attach/sceneStore


+ 2 - 1
src/graphic/Controls/AddPoint.js

@@ -18,8 +18,10 @@ export default class AddPoint {
   }
 
   buildPoint(position) {
+
     if ((Settings.selectLocationMode == Constant.angleLocationMode || Settings.selectLocationMode == Constant.allLocationMode) && Settings.basePointIds.length == 1) {
       Settings.selectBasePointId = Settings.basePointIds[0];
+      console.error(Settings.basePointIds.length)
     }
     let newPoint;
     if (Settings.selectPointCategory == VectorCategory.Point.BasePoint) {
@@ -51,7 +53,6 @@ export default class AddPoint {
         newPoint.getCategory() == VectorCategory.Point.TestPoint
       ) {
         this.testPointIds.push(newPoint.vectorId);
-        console.error(this.testPointIds)
       }
     }
     listenLayer.clear();

+ 1 - 0
src/graphic/Layer.js

@@ -956,6 +956,7 @@ export default class Layer {
         stateService.clearFocusItem();
         this.uiControl.focusVector = null;
         this.uiControl.currentUI = null;
+        Settings.selectBasePointId = null;
         break;
       case LayerEvents.MoveRoadPoint:
         if (!draggingItem || !draggingItem.vectorId) {

+ 1 - 0
src/graphic/Service/PointService.js

@@ -11,6 +11,7 @@ export default class PointService {
   create(position, vectorId) {
     let point = new Point(position, vectorId);
     dataService.addPoint(point);
+    this.updateBasePointIds()
     return point;
   }