|
|
@@ -7,8 +7,6 @@ import { Message } from "@kankan/components/expose-common";
|
|
|
import { ref, nextTick, shallowRef, watch, watchEffect } from "vue";
|
|
|
import { goto } from "./menus/data";
|
|
|
|
|
|
-let sdk: SDK;
|
|
|
-useAsyncSDK().then((a) => (sdk = a));
|
|
|
const fix3ds: { [key in string]: FixPoint3D } = {};
|
|
|
|
|
|
let basePointId: string;
|
|
|
@@ -152,7 +150,6 @@ export const getFix3d = (data: FixPoint) => {
|
|
|
return;
|
|
|
}
|
|
|
if (args.measure) {
|
|
|
- console.log("create", data, args);
|
|
|
let basePoint: BasePoint;
|
|
|
let baseId = data.baseId || basePointId;
|
|
|
if (
|
|
|
@@ -166,6 +163,7 @@ export const getFix3d = (data: FixPoint) => {
|
|
|
}
|
|
|
|
|
|
console.log("create", args);
|
|
|
+ let sdk: SDK = useSDK();
|
|
|
const fix3d = sdk.scene.createFixPoint(args);
|
|
|
if (drawstatus.value === DrawStatus.ing) {
|
|
|
drawingFix3d.value.push(fix3d);
|
|
|
@@ -178,12 +176,14 @@ export const getFix3d = (data: FixPoint) => {
|
|
|
}
|
|
|
|
|
|
if (args.graph) {
|
|
|
- fix3d.bus.on("graphChange", ({ path, center }) => {
|
|
|
- Object.assign(data, { line: path, pos: center });
|
|
|
+ fix3d.bus.on("graphChange", (data) => {
|
|
|
+ console.error(data);
|
|
|
+ // Object.assign(data, { line: path, pos: center });
|
|
|
});
|
|
|
}
|
|
|
fix3ds[data.id] = fix3d;
|
|
|
fixJoinBase(data, fix3d);
|
|
|
+ return fix3d;
|
|
|
};
|
|
|
|
|
|
export const quitMeasure = (data: FixPoint) => {
|