From ea80fe325c94d9082afdd27465047fb13c069544 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=8F=E5=A4=A7=E8=83=86?= <1101282782@qq.com> Date: Thu, 21 Aug 2025 17:00:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=89=B9=E9=87=8F=E6=A8=A1?= =?UTF-8?q?=E5=9E=8B=E7=BB=98=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Obj/Base/BatchModel/index.js | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/src/Obj/Base/BatchModel/index.js b/src/Obj/Base/BatchModel/index.js index 84045dd..af82c3a 100644 --- a/src/Obj/Base/BatchModel/index.js +++ b/src/Obj/Base/BatchModel/index.js @@ -107,16 +107,22 @@ class BatchModel extends Base { // posiArr = [that.options.positions] that.pointArr = posiArr } - posiArr.forEach((item, index) => { - let model = new Model(that.sdk, { - id: 'model' + index, - show: that.options.show, - url: that.options.url, - position: item, - rotate: that.options.type == '点' ? undefined : { x: 0, y: 0, z: array[1] && (array[1][index] || array[1]) } - }) - that.pointArr.push(model) - }) + let params = { + type: that.options.type, + positions: posiArr, + rotate: that.options.type == '点' ? undefined : array[1] + } + that.callback(params) + // posiArr.forEach((item, index) => { + // let model = new Model(that.sdk, { + // id: 'model' + index, + // show: that.options.show, + // url: that.options.url, + // position: item, + // rotate: that.options.type == '点' ? undefined : { x: 0, y: 0, z: array[1] && (array[1][index] || array[1]) } + // }) + // that.pointArr.push(model) + // }) } async linePoint(polygonPositions, spacing) { let boundaryPoints = []; @@ -399,8 +405,8 @@ class BatchModel extends Base { break; } Draw && Draw.start((a, positions) => { - this.options.positions = positions - this.callback(this.options); + this.options.positions = positions; + // this.callback(this.options); (this.options.positions.length || this.options.positions.lng) && BatchModel.computeDis(this) })