From d7c50f6207f0f27f4c20aa96f75b7c0b610b2b23 Mon Sep 17 00:00:00 2001
From: 陈泽平 <chenzeping>
Date: 星期四, 20 五月 2021 11:06:54 +0800
Subject: [PATCH] 管线弹框分析修改

---
 src/components/panel/topicSearch/SewersSelect/SewersAnalysis.vue |   42 ++++++++++++++++++++++++++++--------------
 1 files changed, 28 insertions(+), 14 deletions(-)

diff --git a/src/components/panel/topicSearch/SewersSelect/SewersAnalysis.vue b/src/components/panel/topicSearch/SewersSelect/SewersAnalysis.vue
index ad9b07f..20f74de 100644
--- a/src/components/panel/topicSearch/SewersSelect/SewersAnalysis.vue
+++ b/src/components/panel/topicSearch/SewersSelect/SewersAnalysis.vue
@@ -11,6 +11,7 @@
                 <Flow></Flow>
             </el-tab-pane>
             <el-tab-pane label="妯柇闈�" name="fourth">
+                <!--                <CrossSectional></CrossSectional>-->
                 <el-row>
                     <el-button type="primary" @click="drawLine" size="mini" title="鍦板浘涓婄粯鍒惰杩涜鍒嗘瀽鎴柇闈㈢殑绾�">缁樺埗绾挎</el-button>
                     <el-button type="primary" @click="jdmQuery" size="mini" title="鎴柇闈㈠垎鏋�">鎴柇闈㈠垎鏋�</el-button>
@@ -22,13 +23,16 @@
                 </div>
                 <el-table class="tableBox" :data="tableData" height="150" max-height="200" highlight-current-row
                           style="width: 100%" @row-click="selectRow" size="mini">
-                    <el-table-column prop="pipename" label="绠℃鍚嶇О"></el-table-column>
-                    <el-table-column prop="mediumtype" label="绠℃绫诲瀷" width="80"></el-table-column>
-                    <el-table-column class-name="fixed-table" fixed="right" label="鍥捐〃" width="40">
-                        <template slot-scope="scope">
-                            <el-button @click="selectRow(scope.row)" type="text" size="small">鏌ョ湅</el-button>
-                        </template>
-                    </el-table-column>
+                    <el-table-column prop="mediumtype" label="浠嬭川绫诲瀷" :show-overflow-tooltip="true"></el-table-column>
+                    <el-table-column prop="x" label="鏂潰(缁忓害)" :show-overflow-tooltip="true" width="80"></el-table-column>
+                    <el-table-column prop="y" label="鏂潰(绾害)" :show-overflow-tooltip="true" width="80"></el-table-column>
+                    <el-table-column prop="z" label="鏂潰(楂樼▼)" :show-overflow-tooltip="true" width="80"></el-table-column>
+                    <el-table-column prop="spacing" label="闂磋窛(m)" width="80"></el-table-column>
+                    <!--                    <el-table-column class-name="fixed-table" fixed="right" label="鍥捐〃" width="40">-->
+                    <!--                        <template slot-scope="scope">-->
+                    <!--                            <el-button @click="selectRow(scope.row)" type="text" size="small">鏌ョ湅</el-button>-->
+                    <!--                        </template>-->
+                    <!--                    </el-table-column>-->
                 </el-table>
                 <!--  </el-card>-->
                 <!-- <el-card class="box-card">
@@ -57,6 +61,7 @@
 import Connectivity from './AnalysisChoose/Connectivity'
 import Tube from './AnalysisChoose/Tube'
 import Flow from './AnalysisChoose/Flow'
+// import CrossSectional from './AnalysisChoose/CrossSectional'
 
 export default {
   name: 'SewersAnalysis',
@@ -64,6 +69,7 @@
     Connectivity,
     Tube,
     Flow
+    // CrossSectional
   },
   data () {
     return {
@@ -115,7 +121,8 @@
       lxTableDataResult: [],
 
       // 妯柇闈� 绠℃鏌ヨ缁撴灉 鐨則able琛ㄦ牸鏁版嵁
-      tableData: []
+      tableData: [],
+      obj: {}
 
     }
   },
@@ -151,7 +158,7 @@
     selectPipeLine () {
       window.map.on('click', this.selectClick)
       // 鍏抽棴寮圭獥
-      window.layerFactory.clickSwitch = false
+      // window.mapManager.clickDialogSwitch = false
     },
     // 鍦板浘涓婄偣鍑诲洖璋�
     selectClick (e) {
@@ -215,8 +222,6 @@
     // 杩為�氭�� 璧峰绠℃ table鍒楄〃鏁版嵁 閫夋嫨鏁版嵁浜嬩欢 鐨勭偣鍑讳簨浠�
     linkSelectStart (e) {
       // console.log(e)
-      // console.log('閫夋嫨璧峰绠℃')
-      // this.$refs.singleTable.setCurrentRow(e)
       this.currentSelectStart = e
       if (this.currentSelectStartLine != null) {
         this.currentSelectStartLine.remove()
@@ -586,15 +591,24 @@
       }
       // 宸茬粯鍒剁嚎鍥� 杩涜缁樺埗妯柇闈㈡暟鎹垎鏋�
       const res = await mapApi.getCrossSection(this.hdmParam)
+      console.log(res)
       const dataPoint = res.data.point
+      // 瀛樺偍闂磋窛list
+      const spacingList = res.data.pointInterval.reverse()
+      // console.log(spacingList)
       for (let i = 0; i < dataPoint.length; i++) {
         const obj = {
-          pipename: dataPoint[i].pipelines.extraData.pipename,
-          mediumtype: dataPoint[i].pipelines.extraData.mediumtype
+          mediumtype: dataPoint[i].pipelines.extraData.mediumtype,
+          x: parseFloat(dataPoint[i].crossPoint3D.x).toFixed(4),
+          y: parseFloat(dataPoint[i].crossPoint3D.y).toFixed(4),
+          z: parseFloat(dataPoint[i].crossPoint3D.z).toFixed(4),
+          spacing: spacingList[i - 1]
         }
         this.tableData.push(obj)
       }
-      // console.log(this.tableData, 'this.tableData')
+      // spacingList.reverse()
+      // console.log(spacingList)
+      // console.log(this.tableData)
       this.dealWithData(res)
     },
     dealWithData (e) {

--
Gitblit v1.8.0