deepsea 1 year ago
parent
commit
36e0274962

BIN
dist.zip


+ 9 - 3
src/components/MyTable/index.vue

@@ -25,8 +25,14 @@ export default {
 <style>
 .el-table__header-wrapper,.el-table__body-wrapper,.el-table__cell,tr {
   background-color: transparent !important;
-  color: #fbfbfb! important;
-  font-size: 12px!important;
+  color: #ebebeb !important;
+  font-size: 12px !important;
+}
+
+.el-table__header-wrapper .el-table__cell{
+  color: #fff !important;
+  font-size: 14px !important;
+  font-weight: bold;
 }
 .el-table td.el-table__cell, .el-table th.el-table__cell.is-leaf{
   border-bottom: 0!important;
@@ -44,7 +50,7 @@ tbody tr {
   /* background-color: #141414 !important; */
 }
 .el-table .el-table__cell{
-  padding: 0;
+  padding: 5px 0;
   height: 4.4vh!important;
 }
 

+ 1 - 1
src/components/TabList/index.vue

@@ -731,7 +731,7 @@ export default {
         match_agent_id: this.multipleSelection,
         custom_agent_id: this.multipleSelection,
       };
-      data.planId = plan_id;
+      data.planId = this.currentPlanId;
       this.$store.dispatch("caseList/startPlan", data);
       this.clickBackToAutoCaseList();
     },

+ 3 - 3
src/main.js

@@ -10,13 +10,13 @@ Vue.config.productionTip = false;
 
 var strUrl=window.location.href;
 var strIp = "";
-if(strUrl.indexOf("172.16.50.4")!=-1)
+if(strUrl.indexOf("47.102.97.214")!=-1)
 {
-  strIp = "172.16.50.4:19703";
+  strIp = "47.102.97.214";
 }
 else
 {
-  strIp = "47.102.97.214";
+  strIp = "172.16.50.4:19703";
 }
 
 Vue.use(

+ 7 - 6
src/store/modules/common/mutations.js

@@ -94,14 +94,15 @@ export default {
         window.sdkInstance.changeMode('panorama');
         let player = document.getElementById('player')
         player.appendChild(element)
-        element.style.width = window.innderWidth+'px';
-        element.style.height = window.innderHeight+'px';
+        var elementChild = document.getElementById('house-player');
+        elementChild.style.width = window.innderWidth+'px';
+        elementChild.style.height = window.innderHeight+'px';
         window.renderWidth = window.innderWidth;
         window.renderHeight = window.innderHeight;
-        element.width = (window.innderWidth * 2);
-        element.height = (window.innderHeight * 2);
-        element.style.marginLeft = '0px';
-        element.style.marginTop = '0px';
+        elementChild.width = (window.innderWidth * 2);
+        elementChild.height = (window.innderHeight * 2);
+        elementChild.style.marginLeft = '0px';
+        elementChild.style.marginTop = '0px';
       })
       sessionStorage.setItem('3dMode', 1)
     } else {

+ 65 - 37
src/uwb-sample.js

@@ -455,6 +455,7 @@ export function uwbMain(domId, modelWidth, modelHeight, finalMode, callback) {
       vrBgContainer.style.height = modelHeight + 'px'
       vrBgContainer.style.backgroundColor = 'transparent'
 
+<<<<<<< HEAD
       window.sdkInstance.emit("endLoading", finalMode);
       window.sdkInstance.emit("modeChange", null, finalMode);
       if (!sessionStorage.getItem('3dMode') || sessionStorage.getItem('3dMode') == 0) {
@@ -465,6 +466,38 @@ export function uwbMain(domId, modelWidth, modelHeight, finalMode, callback) {
         }, 500)
       }
       
+=======
+      // sdkInstance.player.mode = finalMode;
+      setTimeout(() => {
+        window.sdkInstance.emit("endLoading", finalMode);
+        window.sdkInstance.emit("modeChange", null, finalMode);
+        if (!sessionStorage.getItem('3dMode') || sessionStorage.getItem('3dMode') == 0) {
+          window.sdkInstance.changeMode(finalMode);
+          setTimeout(() => {
+            var element = document.getElementById('house-player');
+            var container = document.getElementById("ordinary-map")
+            container.style.opacity = 1;
+            let mapDom = document.getElementsByClassName("ordinary-map-container")[0];
+            let style = getComputedStyle(mapDom);
+            let width = parseFloat(style.width);
+            let height = parseFloat(style.height);
+
+            let ratio = 1.8;
+            window.renderWidth = width * ratio;
+            window.renderHeight = height * ratio;
+            window.sdkInstance.sceneRenderer.updateScreenSize(width * ratio, height * ratio);
+            element.style.marginLeft = ((width - (width * ratio)) / 2) + 'px';
+            element.style.marginTop = ((height - (height * ratio)) / 2) + 'px';
+            let playersmall = document.getElementById('playersmall')
+            playersmall.appendChild(element)
+            setTimeout(() => {
+              window.sdkInstance.changeMode('floorplan');
+            })
+          }, 500)
+        }
+
+      }, 3000)
+>>>>>>> 5e321e415e04717de1820b79f7a666b7787daac5
       sdkInstance.on("endLoading", (mode) => {
         console.log(mode, '-----+++++-----')
         vrBgContainer.style.display = "none";
@@ -549,43 +582,38 @@ export function uwbMain(domId, modelWidth, modelHeight, finalMode, callback) {
             let bFirst = true;
             let bool = false;
             let bool1 = false;
-            // intersects.forEach(m => {
-            //   if (m.object.geometry.type != "PlaneBufferGeometry") {
-            //     if (m.object.userData && m.object.userData.benchFlag == true) {
-            //       if (!bool) {
-            //         bool = true;
-            //         //m.object.material = window.shader1;
-            //         ////m.object.scale.set(10, 10, 10)
-            //         //m.object.scale.set(5, 5, 5)
-            //         //outlineObj(m.object)
-            //         // let player = document.getElementById(domId)
-            //         // player.style.display = "none"
-
-            //         if (box) {
-            //           sdkInstance.sceneRenderer.scene.remove(box);
-            //         }
-            //         window.handleBenchClick(m.object.userData.benchId, m.object.userData.bShowRemoteButton)
-
-            //         box = new THREE.BoxHelper(m.object, '#ff0000');  //object 模型
-            //         sdkInstance.sceneRenderer.scene.add(box);
-
-            //         //let ambientLight = new THREE.AmbientLight(0xffffff); //设置环境光
-            //         //sdkInstance.sceneRenderer.scene.add(ambientLight); //将环境光添加到场景中
-            //         //let pointLight = new THREE.PointLight(0xffffff, 1, 0);
-            //         //pointLight.position.set(200, 200, 200); //设置点光源位置
-            //         //sdkInstance.sceneRenderer.scene.add(pointLight); //将点光源添加至场景
-            //       }
-            //       //outlineObj(m.object)
-
-            //       //m.object.material = FXAAShader
-            //     }
-
-            //   } else if (m.object.geometry.type == "PlaneBufferGeometry") {
-            //     if (m.object.userData && m.object.userData.benchFlag == true) {
-            //       window.handleListClick(m.object.userData.benchId)
-            //     }
-            //   }
-            // })
+            intersects.forEach(m => {
+               if (m.object.geometry.type != "PlaneBufferGeometry") {
+                 if (m.object.userData && m.object.userData.benchFlag == true) {
+                   if (!bool) {
+                     bool = true;
+                     //m.object.material = window.shader1;
+                     ////m.object.scale.set(10, 10, 10)
+                     //m.object.scale.set(5, 5, 5)
+                     //outlineObj(m.object)
+                     // let player = document.getElementById(domId)
+                     // player.style.display = "none
+                     if (box) {
+                       sdkInstance.sceneRenderer.scene.remove(box);
+                     }
+                     window.handleBenchClick(m.object.userData.benchId, m.object.userData.bShowRemoteButton)
+                     box = new THREE.BoxHelper(m.object, '#ff0000');  //object 模型
+                     sdkInstance.sceneRenderer.scene.add(box)
+                     //let ambientLight = new THREE.AmbientLight(0xffffff); //设置环境光
+                     //sdkInstance.sceneRenderer.scene.add(ambientLight); //将环境光添加到场景中
+                     //let pointLight = new THREE.PointLight(0xffffff, 1, 0);
+                     //pointLight.position.set(200, 200, 200); //设置点光源位置
+                     //sdkInstance.sceneRenderer.scene.add(pointLight); //将点光源添加至场景
+                   }
+                   //outlineObj(m.object
+                   //m.object.material = FXAAShader
+                 
+               } else if (m.object.geometry.type == "PlaneBufferGeometry") {
+                 if (m.object.userData && m.object.userData.benchFlag == true) {
+                   window.handleListClick(m.object.userData.benchId)
+                 }
+               }
+              }})
             bool = false;
             bool1 = false;
           }

+ 3 - 1
src/views/ordinaryPage/index.less

@@ -159,7 +159,8 @@
 
         .item-title {
           height: 4.17vh;
-          font-size: 22px;
+          font-size: 20px;
+          letter-spacing: -1px;
           font-family: PingFang SC-Bold, PingFang SC;
           font-weight: 400;
           color: #fbfbfb;
@@ -461,6 +462,7 @@
   border-radius: 53px 53px 53px 53px;
   opacity: 1;
   border: 1px solid #DFDFDF;
+  display: none;
 }
 
 .el-icon-circle-check {

+ 14 - 8
src/views/ordinaryPage/index.vue

@@ -27,12 +27,6 @@
                 class="grid-item-background"
                 style="
                   background-color: black;
-                  padding-top: 35px;
-                  padding-bottom: 25px;
-                  padding-left: 9px;
-                  padding-right: 5px;
-                  margin: 10px;
-                  border-radius: 20px;
                 "
               >
                 <div class="grid-item">
@@ -820,7 +814,7 @@ export default {
     window.renderWidth = width * ratio;
     window.renderHeight = height * ratio;
     sessionStorage.setItem('3dMode', 0)
-    uwbMain('playersmall', width * ratio, height * ratio, "floorplan");
+    uwbMain('player', width * ratio, height * ratio, "floorplan");
     
     // window.sdkInstance.sceneRenderer.updateScreenSize(width * ratio, height * ratio);
     setTimeout(() => {
@@ -1001,6 +995,7 @@ export default {
         this.$store.dispatch('caseList/cancelPlan', planId);
         clearInterval(this.autoPlanResultInterval)
         this.clickBackToTaskList()
+        this.isShowAutoCaseList = false;
         return
       }
       this.isShowAutoCaseList = false;
@@ -1340,7 +1335,7 @@ export default {
                   <div class="item-right">
                       <div class="item-text">
                           <div class="item-title">${item.name}
-                            <span onClick="selectBench(${item.id})" class="el-icon-s-platform ${item.status}"></span>
+                            <span onClick="selectBench(${item.id})" class="el-icon-monitor ${item.status}"></span>
                           </div>
                           <div class="item-description">Automation Lab-7E</div>
                           <div class="item-tag">
@@ -4072,4 +4067,15 @@ export default {
 .benchBtnActive {
   filter: brightness(5) drop-shadow(0 2px 3px rgb(255, 255, 255));
 }
+
+.grid-item-background{
+  height: 20vh;
+  width: calc(100% - 10px);
+  border-radius: 10px;
+  margin: auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  position: relative;
+}
 </style>

+ 8 - 6
src/views/ordinaryPage/square.less

@@ -16,17 +16,19 @@
         // margin-top: -30vh;
   
         .grid-item-close {
-          margin-left: 16.69vw;
-          margin-top: -21.94vh;
-          margin-bottom: 14.5vh;
-  
+          // margin-left: 16.69vw;
+          // margin-top: -21.94vh;
+          // margin-bottom: 14.5vh;
+          position: absolute;
+          right: 0;
+          top: 0;
         }
   
         .grid-item {
           width: 18.6vw;
           height: 16.74vh;
-          margin-right: 1.39vw;
-          margin-bottom: 1.94vh;
+          // margin-right: 1.39vw;
+          // margin-bottom: 1.94vh;
   
           img {
             width: 100%;