From 63be6c3a6e0308812cb9f0ab26a15aff293200a0 Mon Sep 17 00:00:00 2001
From: Surpriseplus <845948745@qq.com>
Date: 星期四, 11 五月 2023 16:06:43 +0800
Subject: [PATCH] 模型发布预览修改,属性查询修改

---
 src/components/preview_map.vue |   23 ++++++++++++-----------
 1 files changed, 12 insertions(+), 11 deletions(-)

diff --git a/src/components/preview_map.vue b/src/components/preview_map.vue
index c2a5c09..1705e6a 100644
--- a/src/components/preview_map.vue
+++ b/src/components/preview_map.vue
@@ -945,7 +945,7 @@
           Viewer.camera.flyTo({
             destination: Cesium.Cartesian3.fromDegrees(wkt.coordinates[1], wkt.coordinates[0], height),
           });
-        } else if (type == '3dml') {
+        } else if (type == '3dml' || type == 'fbx' || type == 'ifc' || type == 'rvt') {
           if (this.app.tileset) viewer.scene.primitives.remove(this.app.tileset);
           this.app.tileset = this.createTileset(res);
           var that = this;
@@ -1213,18 +1213,19 @@
 
       } else {
         var std = data.result
-        var val = std.filter((str) => {
-          if (str.type == 1 && str.pid == 1) {
-            return str;
-          }
-          if (str.id == 1 && str.pid == 0) {
-            return str;
-          }
-          if (str.type == 1 && str.cnName == '涓夌淮鍦拌川妯″瀷' || str.cnName == '鍗曚綋妯″瀷' || str.cnName == '娲炲簱妯″瀷') {
-            return str;
+        var val = [];
+        std.filter((str) => {
+          // if (str.type == 1 && str.pid == 1) {
+          //   return str;
+          // }
+          // if (str.id == 1 && str.pid == 0) {
+          //   return str;
+          // }
+          if (str.type == 1) {
+            val.push(str);
           }
           if (str.url != null && str.type == 2 && str.serveType == 'Tileset') {
-            return str;
+            val.push(str);
           }
         });
 

--
Gitblit v1.9.3