浏览代码

列表高度跳转,列表不显示修改、详情关系图斑上图、

maxiaoxiao 5 月之前
父节点
当前提交
7f7c2a4417

+ 5 - 0
src/components/mapView/tablePage.vue

@@ -6,6 +6,7 @@
       :data="table.data"
       v-else
       style="width: 100%"
+      :height="height"
       :show-overflow-tooltip="true"
       header-row-class-name="datatable"
       row-class-name="datarow"
@@ -92,6 +93,10 @@ export default {
       type: Boolean,
       default: true,
     },
+    height: {
+      type: String || Number,
+      default: undefined,
+    },
   },
   data() {
     return {

+ 1 - 85
src/views/basicGeographic/components/config.js

@@ -44,90 +44,6 @@ export const TableHeader = [
 ]
 
 
-// 详情字段
-export const detailInfos = [
-  [
-    [
-      { flag: 'label', value: '申请时间', span: 8 },
-      { flag: 'value', value: 'sqTime', span: 16 }
-    ],
-    [
-      { flag: 'label', value: '申请部门', span: 8 },
-      { flag: 'value', value: 'sqDepartmentBy', span: 16 }
-    ]
-  ],
-  [
-    [
-      { flag: 'label', value: '数据服务', span: 8 },
-      { flag: 'value', value: 'systemName', span: 16 }
-    ],
-    [
-      { flag: 'label', value: '数据类型', span: 8 },
-      { flag: 'value', value: 'zymlTypeName', span: 16 }
-    ]
-  ],
-  [
-    [
-      { flag: 'label', value: '申请范围', span: 4 },
-      { flag: 'value', value: 'sqFw', span: 20 }
-    ],
-  ],
-  [[
-    { flag: 'label', value: '申请理由', span: 4 },
-    { flag: 'value', value: 'sqReason', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '系统名称', span: 4 },
-    { flag: 'value', value: 'systemName', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '调用IP', span: 4 },
-    { flag: 'value', value: 'callIp', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '预期使用时间', span: 4 },
-    { flag: 'value', value: 'sqDeadline', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '附件', span: 4 },
-    { flag: 'value', value: 'attachment', span: 20, isslot: true }
-  ]]
-]
-export const shjlInfos = [
-  [[
-    { flag: 'label', value: '审核结果', span: 4 },
-    { flag: 'value', value: 'jg', span: 20, isslot: true }
-  ]],
-  [[
-    { flag: 'label', value: '审核意见', span: 4 },
-    { flag: 'value', value: 'spReason', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '有效截止日期', span: 4 },
-    { flag: 'value', value: 'deadline', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '审核人', span: 4 },
-    { flag: 'value', value: 'sqUserBy', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '审核时间', span: 4 },
-    { flag: 'value', value: 'spTime', span: 20 }
-  ]],
-]
-export const chInfos = [
-  [[
-    { flag: 'label', value: '撤回时间', span: 4 },
-    { flag: 'value', value: 'sqRevokeTime', span: 20 }
-  ]],
-  [[
-    { flag: 'label', value: '撤回原因', span: 4 },
-    { flag: 'value', value: 'sqRevokeReason', span: 20 }
-  ]],
-]
-
-
-
 
 export const gxConfig = [
   [
@@ -151,4 +67,4 @@ export const gxConfig = [
     }
   ]
 ]
-
+ 

+ 6 - 2
src/views/basicGeographic/components/list.vue

@@ -3,7 +3,7 @@
     <div class="sm-panel-header">
       <span>{{ obj.label }}实体列表</span>
       <span class="closeBtn" :class="`el-icon-s-${fold ? '' : 'un'}fold`" @click="fold = !fold"></span>
-      <span class="closeBtn" @click="isshow = false">&times;</span>
+      <span class="closeBtn" @click="close">&times;</span>
     </div>
     <div>
       <custom-form ref="formRef" :model="model" :config="formConfig">
@@ -13,7 +13,7 @@
         </template>
       </custom-form>
       <!-- :check="true" @selectChange="selectChange" -->
-      <tablePage class="tablePage" :cloumn="cloumn" :table="table" ref="tableDialogRef" @currentChange="searchFun">
+      <tablePage class="tablePage" :cloumn="cloumn" :table="table" height="200" ref="tableDialogRef" @currentChange="searchFun">
         <!-- <template #state="{ row }"></template> -->
         <template #action="{ row }">
           <span class="usable" @click="fly(row)">定位</span>
@@ -63,6 +63,10 @@ export default {
       console.log(this.obj)
       this.reset()
     },
+    close(){
+      this.isshow = false
+      this.$emit("close")
+    },
 
     searchFun(page) {
       this.getTableData(page);

+ 32 - 25
src/views/basicGeographic/index.vue

@@ -1,16 +1,16 @@
 <!--合规性分析-->
 <template>
   <div class="ghzc basicGeographic" :class="!fold ? 'HideLeft' : ''">
-    <!-- @detail="detail" @checkChange="checkChange" -->
+    <!-- @detail="getGraph" @checkChange="checkChange" -->
     <EntityManage class="innerContainer leftPane" @showlist="showlist"></EntityManage>
     <div>
     </div>
-    <List class="innerContainer bottomPane" v-drag ref="list" @click="getData" @graph="detail"></List>
+    <List class="innerContainer bottomPane" v-drag ref="list" @click="getDatas"  @graph="getGraph" @close="removeGeoJSON('enitylist')"></List>
     <div class="sm-panel rightWrap" v-show="showInter" :class="fold ? 'HideRight' : ''">
       <div v-loading="graloading">
         <div class="sm-panel-header">
           <span>实体关系</span>
-          <span class="closeBtn foldBtn" :class="`el-icon-s-${fold ? '' : 'un'}fold`" @click="fold = !fold"></span>
+          <span class="closeBtn gxfoldBtn" :class="`el-icon-s-${fold ? '' : 'un'}fold`" @click="fold = !fold"></span>
           <span class="closeBtn" @click="HideGraph">&times;</span>
         </div>
         <custom-form ref="formRef" :model="pageObj" :config="gxConfig">
@@ -135,7 +135,7 @@ export default {
   },
   created() { },
   mounted() {
-    // this.detail({ entityid: 'MA1001NE103K10350XXXXXXXXXXXXXXX2203020000', entityname: '科尔沁北路' })//MA1001NE103K103501004XXXXXXXXXXX2203040000
+    // this.getGraph({ entityid: 'MA1001NE103K10350XXXXXXXXXXXXXXX2203020000', entityname: '科尔沁北路' })//MA1001NE103K103501004XXXXXXXXXXX2203040000
   },
   methods: {
     showlist(data) {
@@ -152,10 +152,10 @@ export default {
     },
     mouseout() { },
     checkChange(obj, checked) {
-      if (checked) this.getData(obj)
+      if (checked) this.getDatas(obj)
       else removeGeoJSON(`2wentity${obj.id}`)
     },
-    detail(obj) {
+    getGraph(obj) {
       this.showInter = true
       this.graphdata = []
       this.gralinks = []
@@ -164,6 +164,7 @@ export default {
       this.oldclick = []
       this.addOld({ name: obj.entityname, id: obj.entityid, category: 0, data: obj })
       this.getRelationship(obj)
+      this.getDatas(obj,'fly')
     },
     HideGraph() {
       this.showInter = false
@@ -208,20 +209,21 @@ export default {
       this.pageObj = { query_data: '', query_links: '' }
       this.$refs.graphEchart.setOptions(this.graphdata, this.gralinks, categors);
     },
-    getData(obj, type) {
+    getDatas(obj, type) {
       getData({ entityid: obj.id || obj.entityid }).then((res) => {
         if (res.statuscode == 200) {
-          if (type == 'infoto' || type == 'fly') {
+          // if (type == 'infoto' || type == 'fly') {
             this.nowObj = res;
-            this[type]();
-          }
-          else
-            //#facd91
-            res.data.geom.forEach(item => {
-              loadGeoJSON(item.siweigeomewkt, "#55A1E3", { isfly: true }, (data) => {
-                data.name = `2wentity${obj.id}`;
-              });
-            });
+            this[type](true);
+          // } 
+          if(type == 'infoto') {this.fly(true)}
+          // else
+          //   //#facd91
+          //   res.data.geom.forEach(item => {
+          //     loadGeoJSON(item.siweigeomewkt, "#55A1E3", { isfly: true }, (data) => {
+          //       data.name = `2wentity${obj.id}`;
+          //     });
+          //   });
         }
       });
     },
@@ -270,16 +272,21 @@ export default {
         }
       });
     },
-    fly() {
-      this.nowgeoId && removeGeoJSON(this.nowgeoId)
-      this.nowgeoId = 'h' + this.nowObj.data.entityid
+    fly(islist) {
+      if (islist) {
+         removeGeoJSON('enitylist')
+      } else {
+        this.nowgeoId && removeGeoJSON(this.nowgeoId)
+        this.nowgeoId = 'h' + this.nowObj.data.entityid
+      }
       this.nowObj.data.geom.forEach(item => {
         loadGeoJSON(item.siweigeomewkt, "#ff0000", { isfly: true }, (data) => {
-          data.name = this.nowgeoId
+          data.name = islist?'enitylist':this.nowgeoId
         });
       });
     },
     infoto() {
+      this.jbxxData=[]
       this.showinfo = true;
       Object.keys(this.nowObj.data).forEach((key) => {
         this.jbxxData.push({ name: key, value: this.nowObj.data[key], });
@@ -309,7 +316,7 @@ export default {
     transition-property: right, background;
     transition-duration: 0.5s, 1s;
 
-    .foldBtn {
+    .gxfoldBtn {
       right: 40px;
     }
   }
@@ -317,7 +324,7 @@ export default {
   .HideRight {
     right: -40% !important;
 
-    .foldBtn {
+    .gxfoldBtn {
       right: 100%;
     }
   }
@@ -354,8 +361,8 @@ export default {
 
   .bottomPane {
     width: calc(100% - 40px);
-    height: 600px;
-    top: calc(100% - 620px);
+    height: 330px;
+    top: calc(100% - 350px);
     left: 20px;
   }
 }