zjs_project 1 månad sedan
förälder
incheckning
62759d702e
2 ändrade filer med 8 tillägg och 6 borttagningar
  1. 2 1
      src/mixins/loadModel.js
  2. 6 5
      src/pages/webgl_rxdz_test/webgl_rxdz_test.vue

+ 2 - 1
src/mixins/loadModel.js

@@ -103,7 +103,7 @@ export default {
 			// this.setSpaceListWallInfo();
 			this.type = type;//加载类型,1空间加载 2 全局精简加载
 			let arr = this.spaceList.map(it => it.layoutId).filter(it => it != 0);
-            // let arr = [533]
+            // let arr = [554]
 			let parmas = {
 				ids: arr,
 			};
@@ -247,6 +247,7 @@ export default {
 				let signel = arrFrunList.find(it => it.id == space.layoutId);
 				if(allowSpaceId.includes(spaceId) && signel){//只加载允许的空间的布局,其他不加载
 					let md = JSON.parse(signel.modelJson); //获取布局里面的模型信息
+                    // md.modelData = md.modelData ? md.modelData.filter(it=>it.id!='0') : [];
                     console.warn("***布局信息***",this.type,md,md.modelData.map(it=>it.modelName));
 					//遍历模型信息,获取模型列表
 					for (let i = 0; i < md.modelData.length; i++) {

+ 6 - 5
src/pages/webgl_rxdz_test/webgl_rxdz_test.vue

@@ -1160,7 +1160,7 @@
 						directionIndex01 = directionIndex01 == 4 ? 3 : 4; // 往西移动
 					}
 			
-					console.log("要变化的宽度", newWidth, newHeight)
+					console.warn(curSpace.spaceId, "要变化的宽度:", newWidth, "要变化的高度:",newHeight)
 					// 目标宽度
 					if(newHeight > curSpace.spaceHeightMax){
 						newHeight = curSpace.spaceHeightMax; 
@@ -1925,7 +1925,7 @@
 			// 获取墙体数据
             async getHouseTypeSpaceWalls(){
                 let data = {id:this.wallIds}
-                // let data = {id:[2313]}
+                // let data = {id:[2385]}
                 const res = await requestConfig('getHouseTypeSpaceWalls', data, true);
                 console.log("墙体数据:", res.list)
                 let wallList = [];
@@ -1952,7 +1952,7 @@
                     }
                 }
                 this.loadSpaceObjWalls(wallArr, wallList);
-				this.getOverallArrangementDetailsList(2);
+				this.getOverallArrangementDetailsList(1);
             },
 			// 加载单个空间墙体资源
             async loadSpaceObjWalls(wallArr, wallList){
@@ -2227,7 +2227,7 @@
 					return
 				}
 
-				this.changeLayoutModelState(); 
+				this.changeLayoutModelState();
 				console.log("关联空间XXXXX", this.leftSpaces, this.rightSpaces)
 			    for (let index = 0; index < this.leftSpaces.length; index++) {
 			        const element = this.leftSpaces[index];
@@ -2263,7 +2263,7 @@
 			// moveOut:是否外移
 			// moveValue: 移动距离
 			moveWall(spaceObj, direction, moveOut, moveValue){
-			    console.log(`移动的空间的id-------:${spaceObj.spaceId};移动方向:${direction};是否外移:${moveOut};移动距离:${moveValue}`)
+			    console.log(`移动的空间的id-------:${spaceObj.spaceId};移动方向:${direction};是否外移:${moveOut};移动距离:${moveValue}`,spaceObj)
 				const oldSpaceObj = JSON.parse(JSON.stringify(spaceObj))
 				
 			    const cube = this.gltfSpaces.find((item)=>{
@@ -2271,6 +2271,7 @@
 			    })
 			
 			    if(!cube){
+                    console.warn("不存在 cube",this.gltfSpaces)
 			        return
 			    }