From 5685babbcf4eb0b1cbbe1385472d862ce5fbb410 Mon Sep 17 00:00:00 2001
From: Surpriseplus <845948745@qq.com>
Date: 星期四, 06 四月 2023 14:23:53 +0800
Subject: [PATCH] 地质体模型挂载,数据申请页面 添加下载功能

---
 src/views/Archive/index.vue               |   33 +++
 src/views/Tools/LayerTree.vue             |    5 
 src/views/datamanage/dictionaryManage.vue |    3 
 src/views/Synthesis/LeftMenu.vue          |    9 
 src/components/MapView/mapMenuPop.vue     |   92 +++++---
 src/views/Archive/dataApplication.vue     |   22 ++
 src/views/Tools/queryinfo.vue             |    8 
 src/views/datamanage/domainManage.vue     |    1 
 src/views/userManage/roleManage.vue       |   49 ++++
 src/components/MapView/mapSpacePop.vue    |  330 ++++++++++++++++++++++++++++++--
 src/views/datamanage/dataUpdata.vue       |   23 +-
 11 files changed, 482 insertions(+), 93 deletions(-)

diff --git a/src/components/MapView/mapMenuPop.vue b/src/components/MapView/mapMenuPop.vue
index 87b9a75..40471a3 100644
--- a/src/components/MapView/mapMenuPop.vue
+++ b/src/components/MapView/mapMenuPop.vue
@@ -226,6 +226,8 @@
       optionx: [],
       imagePoint: null,
       Layerprimit: null,
+      insertOption: null,
+      isflag: true,
     }
   },
   methods: {
@@ -233,9 +235,12 @@
 
       // this.dialogInsertVisible = false
       // this.dialogVisible = true
+      if (this.isflag) {
+        this.codeForm = res;
+        this.download1();
+        this.isflag = false
+      }
 
-      this.codeForm = res;
-      this.download();
     },
     handleInsertClose() {
       this.$confirm("纭鍏抽棴锛�")
@@ -309,7 +314,7 @@
         encrypt.setPublicKey(res.result)
       }
     },
-    async download() {
+    async download1() {
       if (this.codeForm.password == "") return
 
       var entities = [];
@@ -417,39 +422,45 @@
       // }
     },
     async getInsertApply(res) {
-      var entities = [];
-      var tabs = [];
-      for (var i in this.option) {
-        entities.push(this.option[i].entity)
-        tabs.push(this.option[i].tabDesc)
-      }
-      var std = [];
-      for (var i in this.ruleForm.depname) {
-        std.push(this.ruleForm.depname[i].name)
-      }
 
-      var obj = {
-        pwd: encr(this.codeForm.password),
-        entities: entities,
-        wkt: this.listdata.wkt,
-        filter: null,
-        ids: null,
-        depcode: null,
-        dirs: null,
-        depcodes: std,
-        descr: res.descr,
-        tabs: tabs
-      }
-      const data = await apply_insertApply(JSON.stringify(obj))
-      if (data.code != 200) {
-        this.$message.error("鏁版嵁鐢宠澶辫触")
-        return
-      }
-      this.$message({
-        message: "鏁版嵁鐢宠鎴愬姛",
-        type: "success",
-      })
+      if (!this.isflag) {
+        var entities = [];
+        var tabs = [];
+        if (this.option.length != res.tabs.length) {
+          return
+        }
 
+        for (var i in this.option) {
+          entities.push(this.option[i].entity)
+          tabs.push(this.option[i].tabDesc)
+        }
+        var std = [];
+        for (var i in this.ruleForm.depname) {
+          std.push(this.ruleForm.depname[i].name)
+        }
+        var obj = {
+          pwd: encr(this.codeForm.password),
+          entities: entities,
+          wkt: this.listdata.wkt,
+          filter: null,
+          ids: null,
+          depcode: null,
+          dirs: null,
+          depcodes: std,
+          descr: res.descr,
+          tabs: tabs
+        }
+        const data = await apply_insertApply(JSON.stringify(obj))
+        if (data.code != 200) {
+          this.$message.error("鏁版嵁鐢宠澶辫触")
+          return
+        }
+        this.$message({
+          message: "鏁版嵁鐢宠鎴愬姛",
+          type: "success",
+        })
+        this.isflag = true;
+      }
     },
 
 
@@ -478,6 +489,7 @@
         "&pwd=" +
         encodeURIComponent(rspwd)
       $("#Iframe1").attr("src", url).click()
+      // this.isflag = true;
     },
     handleCloseDown() {
       this.$confirm("纭鍏抽棴锛�")
@@ -917,18 +929,26 @@
     },
   },
   created() {
+
     this.setTableAll()
+
   },
   mounted() {
+
     this.$bus.$on("changeMapMenuTop", res => {
       if (res == "true") {
         this.setTableAll()
       }
     })
-    this.$bus.$on("setInsertDown", res => {
+    this.$bus.$on("setInsertDown2", res => {
       this.getInsertDown(res)
     })
-    this.$bus.$on("setInsertApply", res => {
+    this.$bus.$on("setInsertDown1", res => {
+
+      this.getInsertDown(res)
+    })
+    this.$bus.$on("setInsertApply1", res => {
+
       this.getInsertApply(res)
     })
   },
diff --git a/src/components/MapView/mapSpacePop.vue b/src/components/MapView/mapSpacePop.vue
index 309d420..359ce56 100644
--- a/src/components/MapView/mapSpacePop.vue
+++ b/src/components/MapView/mapSpacePop.vue
@@ -29,13 +29,14 @@
         <el-form-item v-if="spaceLayer == 'sexplorationpoint'">
           <el-button
             size="small"
-            @click="spaceHistogram( )"
+            @click="spaceHistogram()"
             plain
           >鏌辩姸鍥�</el-button>
-          <!-- <el-button
+          <el-button
             plain
             size="small"
-          >鍓栧垏鍥�</el-button> -->
+            @click="spaceGeobody()"
+          >鍦拌川浣�</el-button>
         </el-form-item>
       </el-form>
       <!-- <el-form
@@ -343,7 +344,6 @@
       imagePoint: null,
       domainsLayer: null,
       querytype: null,
-
       formSql: {
         field: "",
         condition: "",
@@ -351,6 +351,16 @@
         type: "",
         date: "",
       },
+      geobodyCount: null,
+      outlineList: [
+        { 'name': '绮夎川榛忓湡', 'color': 'rgba(139,106,77,1)' },
+        { 'name': '娣ゆ偿璐ㄧ矇鍦�', 'color': 'rgba(141,85,69,1)' },
+        { 'name': '鍦嗙牼', 'color': 'rgba(102,166,184,1)' },
+        { 'name': '鍗电煶', 'color': 'rgba(54,83,173,1)' },
+        { 'name': '娉ュ博', 'color': 'rgba(47,30,13,1)' },
+        { 'name': '缁嗙爞', 'color': 'rgba(93,88,15,1)' },
+        { 'name': '涓爞', 'color': 'rgba(164,140,21,1)' }
+      ]
     }
   },
   watch: {
@@ -729,7 +739,7 @@
 
 
           this.tableData = val;
-
+          this.geobodyCount = data.count;
           this.showHistogramLayer(data.count)
           this.$refs.filterTable.doLayout();
           var that = this;
@@ -793,6 +803,7 @@
         gid: res.gid,
         name: this.spaceLayer,
       }
+
       const data1 = await dataQuerySelectWktById(param)
       if (data1.code != 200) {
         this.$message.error("鍒楄〃璋冪敤澶辫触")
@@ -808,28 +819,21 @@
       }
       var data = await dataQuerySelectByPage(obj)
       if (data.code != 200) { return }
+
       if (data.result.length != 0) {
         var val = data.result;
-        //鍐掓场鎺掑簭
-        for (var i = 0; i < val.length; i++) {
-          for (var u = i + 1; u < val.length; u++) {
-            if (val[i].botdepth > val[u].botdepth) {
-              var num = val[i];
-              val[i] = val[u];
-              val[u] = num;
-            }
-          }
-        }
+        // //鍐掓场鎺掑簭
+        // for (var i = 0; i < val.length; i++) {
+        //   for (var u = i + 1; u < val.length; u++) {
+        //     if (val[i].botdepth > val[u].botdepth) {
+        //       var num = val[i];
+        //       val[i] = val[u];
+        //       val[u] = num;
+        //     }
+        //   }
+        // }
 
-        var outlineList = [
-          { 'name': '绮夎川榛忓湡', 'color': 'rgba(139,106,77,1)' },
-          { 'name': '娣ゆ偿璐ㄧ矇鍦�', 'color': 'rgba(141,85,69,1)' },
-          { 'name': '鍦嗙牼', 'color': 'rgba(102,166,184,1)' },
-          { 'name': '鍗电煶', 'color': 'rgba(54,83,173,1)' },
-          { 'name': '娉ュ博', 'color': 'rgba(47,30,13,1)' },
-          { 'name': '缁嗙爞', 'color': 'rgba(93,88,15,1)' },
-          { 'name': '涓爞', 'color': 'rgba(164,140,21,1)' }
-        ]
+        var outlineList = this.outlineList
         var num = res.elev;
         var height = 0;
         for (var i = 0; i < val.length; i++) {
@@ -841,9 +845,7 @@
               return res
             }
           })
-
           line = col[0].color
-
           var height = num - val[i].botdepth
           var layer = Viewer.entities.add({
             position: Cesium.Cartesian3.fromDegrees(coord[0], coord[1]),
@@ -864,6 +866,8 @@
           num -= val[i].botdepth;
           this.$store.state.histogramLayer.push(layer)
         }
+      } else {
+        return this.$message('鏌ユ棤鏁版嵁');
       }
       this.$store.state.histLenged = true;
     },
@@ -884,6 +888,14 @@
         )
         window.histogramHandler = null
       }
+      var entitys = Viewer.entities._entities._array;
+      for (var i = 0; i < entitys.length; i++) {
+        if (entitys[i]._name === "鍦拌川浣撴ā鍨�") {
+          Viewer.entities.remove(entitys[i]);
+          i--;
+        }
+      }
+      this.geobodyCount = null;
       var that = this;
       sgworld.Creator.createSimpleGraphic('rectangle', { showSize: false }, function (entity) {
         sgworld.Creator.SimpleGraphic.remove(entity.id);
@@ -891,6 +903,272 @@
       });
 
     },
+    async spaceGeobody() {
+      var entitys = Viewer.entities._entities._array;
+      for (var i = 0; i < entitys.length; i++) {
+        if (entitys[i]._name === "鍦拌川浣撴ā鍨�") {
+          Viewer.entities.remove(entitys[i]);
+          i--;
+        }
+      }
+
+      if (this.geobodyCount) {
+
+        var obj = {
+          pageIndex: 1,
+          pageSize: this.geobodyCount,
+          wkt: this.listdata.wkt,
+          name: this.listdata.name
+        }
+        const data = await dataQuerySelectByPage(obj)
+        if (data.code != 200) {
+          return
+        }
+        var val = data.result;
+        var std = [];
+        for (var i in val) {
+          var param = {
+            gid: val[i].gid,
+            name: this.spaceLayer,
+          }
+
+          const data1 = await dataQuerySelectWktById(param)
+          if (data1.code != 200) {
+            this.$message.error("鍒楄〃璋冪敤澶辫触")
+          }
+          var val1 = decr(data1.result)
+          var wkt = this.$wkt.parse(val1)
+          var coord = wkt.coordinates
+          var obj = {
+            pageIndex: 1,
+            pageSize: 10,
+            name: 'sexplorationpointstratum',
+            filter: "exppointid = '" + val[i].exppointid + "'"
+          }
+          var data2 = await dataQuerySelectByPage(obj)
+
+          if (data2.code == 200) {
+
+            std.push({
+              bh: val[i].exppointid,
+              X: coord[0],
+              Y: coord[1],
+              Z: val[i].elev,
+              soilLayers: data2.result
+            })
+          }
+        }
+        this.setLayerByZFBH(std);
+      } else {
+        return this.$message('鏈煡璇㈠埌杞瓟鐐规暟鎹�,鏃犳硶鐢熸垚鍦拌川浣�');
+      }
+    },
+    setLayerByZFBH(res) {
+      var list = [
+        { 'name': '绮夎川榛忓湡', 'color': [139, 106, 77, 1] },
+        { 'name': '娣ゆ偿璐ㄧ矇鍦�', 'color': [141, 85, 69, 1] },
+        { 'name': '鍦嗙牼', 'color': [102, 166, 184, 1] },
+        { 'name': '鍗电煶', 'color': [54, 83, 173, 1] },
+        { 'name': '娉ュ博', 'color': [47, 30, 13, 1] },
+        { 'name': '缁嗙爞', 'color': [93, 88, 15, 1] },
+        { 'name': '涓爞', 'color': [164, 140, 21, 1] }
+      ]
+      for (var i = 0; i < list.length; i++) {
+        var out_color = list[i].color
+        var color = new Cesium.Color(out_color[0] / 255.0, out_color[1] / 255.0, out_color[2] / 255.0).withAlpha(0.9)
+        this.CreateLayerByZFBH(list[i].name, res, color)
+
+      }
+      // var color = new Cesium.Color(139 / 255, 106 / 255, 77 / 255).withAlpha(0.9)
+      // this.CreateLayerByZFBH("娣ゆ偿璐ㄧ矇鍦�", res, color)
+
+    },
+    CreateLayerByZFBH(zfbh, jsonObj, materialColor) {
+
+      var featurePoints = [];
+      var featurePoints1 = [];
+      let points = turf.featureCollection([]);
+      for (let i = 0; i < jsonObj.length; i++) {
+        var p = jsonObj[i];
+        var layers = p.soilLayers;
+        points.features.push(turf.point([parseFloat(p.X), parseFloat(p.Y)], { alt: p.Z }));
+        for (let j = 0; j < layers.length; j++) {
+          let obj = layers[j];
+
+          if (obj.geoname == zfbh) {
+            if (j == 0) {
+
+              featurePoints.push(...[parseFloat(p.X), parseFloat(p.Y), parseFloat(p.Z)]);
+              featurePoints1.push(...[parseFloat(p.X), parseFloat(p.Y), (parseFloat(p.Z) - parseFloat(obj.botdepth))]);
+            } else {
+              let obj_height = this.GetRealHeight(j, layers, p.Z);
+
+              featurePoints.push(...[parseFloat(p.X), parseFloat(p.Y), parseFloat(obj_height.topHeight)]);
+              featurePoints1.push(...[parseFloat(p.X), parseFloat(p.Y), parseFloat(obj_height.bottomHeight)]);
+
+            }
+
+          }
+        }
+      }
+      this.CreateSoilLayer(featurePoints, featurePoints1, materialColor);
+    },
+    CreateSoilLayer(abovePoints, underPoints, materialColor) {
+      let aboveCollection = this.CreateCollectionByArray(abovePoints);
+      let underCollection = this.CreateCollectionByArray(underPoints);
+      //璁$畻鎻掑��
+      let options = { gridType: "points", property: "alt", units: "miles" };
+      let aboveGrid = turf.interpolate(aboveCollection, 0.01, options);
+      let underGrid = turf.interpolate(underCollection, 0.01, options);
+      //鍒涘缓tin闈�
+      let aboveTin = turf.tin(aboveGrid, "alt");
+      let underTin = turf.tin(underGrid, "alt");
+      //鑾峰彇tin闈㈢殑鍑犱釜椤剁偣
+      let aboveHull = turf.convex(aboveTin);
+      let underHull = turf.convex(underTin);
+
+      //缁勮椤跺簳闈㈠洓涓《鐐�
+      this.CreateRoundMian(aboveTin, aboveHull, underTin, underHull, materialColor);
+      //鍒涘缓闈�
+      this.CreateTin(aboveTin, materialColor);
+      this.CreateTin(underTin, materialColor);
+    },
+
+    CreateRoundMian(tinArr, hull, tinArr1, hull1, materialColor) {
+      if (!hull) {
+        return;
+      }
+      let left = turf.lineIntersect(tinArr, turf.lineString([[hull.geometry.coordinates[0][0][0], hull.geometry.coordinates[0][0][1]], [hull.geometry.coordinates[0][1][0], hull.geometry.coordinates[0][1][1]]]));
+      let right = turf.lineIntersect(tinArr, turf.lineString([[hull.geometry.coordinates[0][1][0], hull.geometry.coordinates[0][1][1]], [hull.geometry.coordinates[0][2][0], hull.geometry.coordinates[0][2][1]]]));
+      let top = turf.lineIntersect(tinArr, turf.lineString([[hull.geometry.coordinates[0][2][0], hull.geometry.coordinates[0][2][1]], [hull.geometry.coordinates[0][3][0], hull.geometry.coordinates[0][3][1]]]));
+      let bottom = turf.lineIntersect(tinArr, turf.lineString([[hull.geometry.coordinates[0][3][0], hull.geometry.coordinates[0][3][1]], [hull.geometry.coordinates[0][4][0], hull.geometry.coordinates[0][4][1]]]));
+      let left1 = turf.lineIntersect(tinArr1, turf.lineString([[hull1.geometry.coordinates[0][0][0], hull1.geometry.coordinates[0][0][1]], [hull1.geometry.coordinates[0][1][0], hull1.geometry.coordinates[0][1][1]]]));
+      let right1 = turf.lineIntersect(tinArr1, turf.lineString([[hull1.geometry.coordinates[0][1][0], hull1.geometry.coordinates[0][1][1]], [hull1.geometry.coordinates[0][2][0], hull1.geometry.coordinates[0][2][1]]]));
+      let top1 = turf.lineIntersect(tinArr1, turf.lineString([[hull1.geometry.coordinates[0][2][0], hull1.geometry.coordinates[0][2][1]], [hull1.geometry.coordinates[0][3][0], hull1.geometry.coordinates[0][3][1]]]));
+      let bottom1 = turf.lineIntersect(tinArr1, turf.lineString([[hull1.geometry.coordinates[0][3][0], hull1.geometry.coordinates[0][3][1]], [hull1.geometry.coordinates[0][4][0], hull1.geometry.coordinates[0][4][1]]]));
+      // console.log(left);
+      // console.log(intPoints);
+      // console.log(tinArr);
+      this.SetAltAttribut(tinArr, left);
+      this.SetAltAttribut(tinArr, right);
+      this.SetAltAttribut(tinArr, top);
+      this.SetAltAttribut(tinArr, bottom);
+      this.SetAltAttribut(tinArr1, left1);
+      this.SetAltAttribut(tinArr1, right1);
+      this.SetAltAttribut(tinArr1, top1);
+      this.SetAltAttribut(tinArr1, bottom1);
+      ///缁樺埗闈�
+      this.CreateSoilLayerRound(left, left1, materialColor);
+      this.CreateSoilLayerRound(right, right1, materialColor);
+      this.CreateSoilLayerRound(top, top1, materialColor);
+      this.CreateSoilLayerRound(bottom, bottom1, materialColor);
+    },
+    SetAltAttribut(tinarr, points) {
+      for (let i = 0; i < tinarr.features.length; i++) {
+        for (let j = 0; j < points.features.length; j++) {
+          if (!turf.booleanDisjoint(tinarr.features[i].geometry, points.features[j].geometry)) {
+            for (let n = 0; n < tinarr.features[i].geometry.coordinates[0].length; n++) {
+              if (tinarr.features[i].geometry.coordinates[0][n][0] == points.features[j].geometry.coordinates[0] && tinarr.features[i].geometry.coordinates[0][n][1] == points.features[j].geometry.coordinates[1]) {
+                if (n == 0) {
+                  points.features[j].properties.alt = tinarr.features[i].properties.a;
+                  break;
+                }
+                if (n == 1) {
+                  points.features[j].properties.alt = tinarr.features[i].properties.b;
+                  break;
+                }
+                if (n == 2) {
+                  points.features[j].properties.alt = tinarr.features[i].properties.c;
+                  break;
+                }
+              }
+
+            }
+          }
+        }
+      }
+    },
+    CreateCollectionByArray(arr) {
+      let newCollection = turf.featureCollection([]);
+      for (let i = 0; i < arr.length; i += 3) {
+        let tmpPoint = turf.point([arr[i], arr[i + 1]], {
+          alt: arr[i + 2]
+        });
+        newCollection.features.push(tmpPoint);
+      }
+      return newCollection;
+    },
+
+    CreateTin(tin, materialColor) {
+      for (let n = 0; n < tin.features.length; n++) {
+        let geoms = tin.features[n].geometry.coordinates[0];
+
+        let points = [];
+        let p1 = new Cesium.Cartesian3.fromDegrees(geoms[0][0], geoms[0][1], tin.features[n].properties.a);
+        let p2 = new Cesium.Cartesian3.fromDegrees(geoms[1][0], geoms[1][1], tin.features[n].properties.b);
+        let p3 = new Cesium.Cartesian3.fromDegrees(geoms[2][0], geoms[2][1], tin.features[n].properties.c);
+        points.push(p1)
+        points.push(p2)
+        points.push(p3)
+        let aa = Viewer.entities.add({
+          name: '鍦拌川浣撴ā鍨�',
+          polygon: {
+            hierarchy: new Cesium.PolygonHierarchy(points),
+            material: materialColor,
+            // material: new Cesium.Color(Math.random() * 255, Math.random() * 255, Math.random() * 255),
+            perPositionHeight: true
+          }
+        });
+        Viewer.flyTo(aa)
+      }
+    },
+    CreateSoilLayerRound(above, under, materialColor) {
+      for (let i = 0; i < under.features.length; i++) {
+        above.features.push(under.features[under.features.length - 1 - i]);
+      }
+
+      let points = [];
+      for (let j = 0; j < above.features.length; j++) {
+        let geo = above.features[j].geometry.coordinates;
+        let alt = above.features[j].properties.alt;
+        let p = new Cesium.Cartesian3.fromDegrees(geo[0], geo[1], alt);
+        points.push(p);
+      }
+      Viewer.entities.add({
+        name: '鍦拌川浣撴ā鍨�',
+        polygon: {
+          hierarchy: new Cesium.PolygonHierarchy(points),
+          material: materialColor,
+
+          perPositionHeight: true
+        }
+      });
+    },
+    GetRealHeight(index, arr, parentZ) {
+
+      var top = 0;
+      var bottom = 0;
+      var std = 0;
+      var start = index + 1
+      var end = index - 1;
+      for (let i = 0; i < start; i++) {
+        std += parseFloat(arr[i].botdepth)
+
+        if (i == end) {
+
+          top = parseFloat(parentZ - std).toFixed(6);
+
+        }
+
+        bottom = parseFloat(parentZ - std).toFixed(6);
+      }
+
+
+      return {
+        topHeight: top,
+        bottomHeight: bottom
+      };
+    },
     async spaceLocation(index, row) {
       var param = {
         gid: row.gid,
diff --git a/src/views/Archive/dataApplication.vue b/src/views/Archive/dataApplication.vue
index 4f667c4..158843e 100644
--- a/src/views/Archive/dataApplication.vue
+++ b/src/views/Archive/dataApplication.vue
@@ -168,6 +168,13 @@
               plain
               @click="handlDetails(scope.$index, scope.row)"
             >{{ $t("dataApply.details") }}</el-button>
+            <el-button
+              v-show="scope.row.guid != null"
+              type="success"
+              size="mini"
+              plain
+              @click="handlDownload(scope.$index, scope.row)"
+            >{{ $t("common.download") }}</el-button>
           </template>
         </el-table-column>
       </el-table>
@@ -189,7 +196,6 @@
       :title="$t('dataApply.details')"
       :visible.sync="dialogDetailsVisible"
       width="50%"
-      :before-close="handleClose"
     >
       <div>
         <el-form
@@ -278,6 +284,11 @@
         </el-table>
       </div>
     </el-dialog>
+    <iframe
+      id="downFrame"
+      src=""
+      style="display: none; border: 0; padding: 0; height: 0; width: 0"
+    ></iframe>
   </div>
 </template>
 
@@ -291,6 +302,8 @@
   apply_updateForReject,
   apply_updateForResubmit,
 } from "../../api/api";
+import $ from 'jquery'
+import { getToken } from '@/utils/auth';
 export default {
   //import寮曞叆鐨勭粍浠堕渶瑕佹敞鍏ュ埌瀵硅薄涓墠鑳戒娇鐢�
   components: {
@@ -372,6 +385,7 @@
         return this.$message.error("鍒楄〃璋冪敤澶辫触");
       }
       this.detailsFrom.tableData = data1.result;
+
     },
     async handleReApply(index, row) {
       const data = await apply_updateForResubmit({ applyid: row.id });
@@ -405,6 +419,12 @@
       this.detailsFrom.statued = row.status;
       this.dialogDetailsVisible = true;
     },
+    async handlDownload(index, row) {
+
+      var token = getToken()
+      var url = BASE_URL + "/dataLib/downloadFile?token=" + token + "&guid=" + row.guid;
+      $("#downFrame").attr("src", url).click();
+    },
     matchState(state = "", reg) {
       var row = state.row;
       if (
diff --git a/src/views/Archive/index.vue b/src/views/Archive/index.vue
index 4c71eac..c4c5f86 100644
--- a/src/views/Archive/index.vue
+++ b/src/views/Archive/index.vue
@@ -840,6 +840,7 @@
       width="90%"
       top="10vh"
       :close-on-click-modal="false"
+      :before-close="handleMaptClose"
     >
       <div style="height:73vh">
         <map-sdk v-if='showMapVisible'></map-sdk>
@@ -1131,7 +1132,7 @@
             <el-button
               class="primary"
               size="small"
-              @click="getInsertDown"
+              @click="getInsertDownx"
             >{{
               $t("common.confirm")
             }}</el-button>
@@ -1407,7 +1408,7 @@
         .catch(_ => { })
     },
     downloadx() {
-      this.$bus.$emit("setInsertDown", this.codeForm)
+      this.$bus.$emit("setInsertDown2", this.codeForm)
       // 
     },
     closeDownx() {
@@ -1417,7 +1418,7 @@
         repassword: '',
       }
     },
-    async getInsertDown() {
+    async getInsertDownx() {
 
       this.dialogInsertVisible = false;
       this.dialogVisible1 = false;
@@ -1434,6 +1435,7 @@
         for (var i in this.ruleForm.depname) {
           std.push(this.ruleForm.depname[i].name)
         }
+
         obj = {
           pwd: encr(this.codeForm.password),
           entities: entities,
@@ -1466,8 +1468,10 @@
         }
         var dirs = null;
         if (this.listData.dirs) {
+
           dirs = this.listData.dirs
         }
+
         obj = {
           pwd: encr(this.codeForm.password),
           entities: [this.listBankData.name], // bpachydrogeology,bhydrogeologyattach
@@ -1775,6 +1779,29 @@
       this.$store.state.download = true;
 
     },
+
+    handleMaptClose() {
+      this.dialogMapVisible = false;
+      this.showMapVisible = false;
+      this.$store.state.mapMenuBoolean = false;
+      this.$store.state.mapMenuBoxFlag = null;
+      this.$store.state.mapPopBoolean = false;
+      this.$store.state.mapPopBoxFlag = false;
+      this.$store.state.download = false;
+      if (window.sgworld) {
+        window.sgworld.Creator.SimpleGraphic.clear();
+        for (var i in this.$store.state.queryInfo) {
+          window.sgworld.Viewer.entities.remove(this.$store.state.queryInfo[i]);
+        }
+      }
+
+      this.$store.state.queryInfo = [];
+      if (this.$store.state.primitLayer != null) {
+        sgworld.Viewer.entities.remove(this.$store.state.primitLayer);
+        sgworld.Creator.DeleteObject(this.$store.state.primitLayer);
+        this.$store.state.primitLayer = null;
+      }
+    },
     downloadMap(index, rows) {
       var token = getToken()
       var url = BASE_URL + "/dataLib/downloadFile?token=" + token + "&guid=" + rows.guid + "&pwd=" + rows.pwd;
diff --git a/src/views/Synthesis/LeftMenu.vue b/src/views/Synthesis/LeftMenu.vue
index ea36c62..db72ab2 100644
--- a/src/views/Synthesis/LeftMenu.vue
+++ b/src/views/Synthesis/LeftMenu.vue
@@ -245,7 +245,7 @@
             <el-button
               class="primary"
               size="small"
-              @click="getInsertDown"
+              @click="getInsertDownz()"
             >{{
               $t("common.confirm")
             }}</el-button>
@@ -3020,7 +3020,7 @@
       this.dialogInsertVisible = true;
     },
     downloadx() {
-      this.$bus.$emit("setInsertDown", this.codeForm)
+      this.$bus.$emit("setInsertDown1", this.codeForm)
       this.closeDownx();
     },
     handleCloseDown1() {
@@ -3055,12 +3055,12 @@
         })
         .catch(_ => { })
     },
-    getInsertDown() {
+    getInsertDownz() {
       this.dialogInsertVisible = false;
       // this.dialogVisible1 = true;
       // 
 
-      this.$bus.$emit("setInsertApply", this.ruleForm)
+      this.$bus.$emit("setInsertApply1", this.ruleForm)
     },
     handleExtentClose() {
       this.dialogExtentVisible = false
@@ -3073,6 +3073,7 @@
     }
   },
   mounted() {
+    this.$bus.$off();
     this.measureData = new Map();
     this.colorAll = {
       point: Cesium.Color.fromCssColorString("#ff0000"),
diff --git a/src/views/Tools/LayerTree.vue b/src/views/Tools/LayerTree.vue
index 04cc9d1..0e7c5e3 100644
--- a/src/views/Tools/LayerTree.vue
+++ b/src/views/Tools/LayerTree.vue
@@ -1153,6 +1153,7 @@
     },
 
     async setproChange(res) {
+
       this.$store.state.pigCode = res;
       if (res) {
         var obj = {
@@ -1176,7 +1177,9 @@
         }
         this.setChangeProLayer();
       } else {
-        this.$store.state.isProjectLayer = [];
+
+        this.$store.state.pigCode = null
+        this.setChangeWMS();
       }
     },
     setChangeProLayer() {
diff --git a/src/views/Tools/queryinfo.vue b/src/views/Tools/queryinfo.vue
index 349ff1a..bb7d8ad 100644
--- a/src/views/Tools/queryinfo.vue
+++ b/src/views/Tools/queryinfo.vue
@@ -123,7 +123,13 @@
         )
         window.histogramHandler = null
       }
-
+      var entitys = Viewer.entities._entities._array;
+      for (var i = 0; i < entitys.length; i++) {
+        if (entitys[i]._name === "鍦拌川浣撴ā鍨�") {
+          Viewer.entities.remove(entitys[i]);
+          i--;
+        }
+      }
       this.$store.state.histLenged = false;
     },
     // 鎵撳紑寮圭獥
diff --git a/src/views/datamanage/dataUpdata.vue b/src/views/datamanage/dataUpdata.vue
index 5389afc..43b1ab5 100644
--- a/src/views/datamanage/dataUpdata.vue
+++ b/src/views/datamanage/dataUpdata.vue
@@ -2290,14 +2290,15 @@
                 this.multipleSelection[this.taskStatus].path
               ) {
                 this.tableData[i].status = "璐ㄦ鎴愬姛";
+
               }
             }
-            if (this.progress == 1) {
-              clearInterval(this.setIntel);
-              this.setIntel = null;
-              this.taskStatus++;
-              this.getStartTaskStatus();
-            }
+            // if (this.progress == 1) {
+            clearInterval(this.setIntel);
+            this.setIntel = null;
+            this.taskStatus++;
+            this.getStartTaskStatus();
+            // }
           } else {
             //浠诲姟澶辫触
             for (var i in this.tableData) {
@@ -2349,11 +2350,11 @@
                 }
               }
             }
-            if (this.progress == 1) {
-              clearInterval(this.setIntel);
-              this.setIntel = null;
-              this.loading = false;
-            }
+            // if (this.progress == 1) {
+            clearInterval(this.setIntel);
+            this.setIntel = null;
+            this.loading = false;
+            // }
           } else {
             //浠诲姟澶辫触
             for (var i in this.tableData) {
diff --git a/src/views/datamanage/dictionaryManage.vue b/src/views/datamanage/dictionaryManage.vue
index 3a95c3f..28dc766 100644
--- a/src/views/datamanage/dictionaryManage.vue
+++ b/src/views/datamanage/dictionaryManage.vue
@@ -22,7 +22,6 @@
         <el-tree
           :data="domainData"
           :props="defaultProps"
-          :default-expand-all="true"
           @node-click="getTableDesc"
           :filter-node-method="filterNode"
           ref="tree"
@@ -679,7 +678,7 @@
     },
 
     handleSizeChange(val) {
-      thihs.listData.pageIndex = 1;
+      this.listData.pageIndex = 1;
       this.listData.pageSize = val;
       this.startQueryNameData();
     },
diff --git a/src/views/datamanage/domainManage.vue b/src/views/datamanage/domainManage.vue
index db8557e..1c368d0 100644
--- a/src/views/datamanage/domainManage.vue
+++ b/src/views/datamanage/domainManage.vue
@@ -21,7 +21,6 @@
           <el-tree
             :data="domainData"
             :props="defaultProps"
-            :default-expand-all="true"
             @node-click="toggleTabs"
             :filter-node-method="filterNode"
             ref="tree"
diff --git a/src/views/userManage/roleManage.vue b/src/views/userManage/roleManage.vue
index 9409ec5..26fb392 100644
--- a/src/views/userManage/roleManage.vue
+++ b/src/views/userManage/roleManage.vue
@@ -200,7 +200,7 @@
         >
           <template slot-scope="scope">
             <span v-if="scope.row.isAdmin == 1">鏄� </span>
-            <span v-else-if="scope.row.isAdmin == 0">鍚�</span>
+            <span v-else>鍚�</span>
           </template>
         </el-table-column>
         <el-table-column
@@ -349,14 +349,25 @@
             :label="$t('userManage.RM.isAdmin')"
             :label-width="formLabelWidth"
           >
-            <el-radio
-              v-model="insertform.isAdmin"
+            <!-- <el-radio
+           
               label="1"
             >鏄�</el-radio>
             <el-radio
               v-model="insertform.isAdmin"
               label="0"
-            >鍚�</el-radio>
+            >鍚�</el-radio> -->
+            <el-select
+              style="width:85%"
+              v-model="insertform.isAdmin"
+            >
+              <el-option
+                v-for="item in options"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value"
+              ></el-option>
+            </el-select>
           </el-form-item>
           <el-form-item
             :label="$t('userManage.RM.remarks')"
@@ -452,14 +463,25 @@
             :label="$t('userManage.RM.isAdmin')"
             :label-width="formLabelWidth"
           >
-            <el-radio
+            <!-- <el-radio
               v-model="updateform.isAdmin"
               label="1"
             >鏄�</el-radio>
             <el-radio
               v-model="updateform.isAdmin"
               label="0"
-            >鍚�</el-radio>
+            >鍚�</el-radio> -->
+            <el-select
+              style="width:85%"
+              v-model="updateform.isAdmin"
+            >
+              <el-option
+                v-for="item in options"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value"
+              ></el-option>
+            </el-select>
           </el-form-item>
           <el-form-item
             :label="$t('userManage.RM.describe')"
@@ -663,6 +685,19 @@
       styleVar: {
         height: "calc(100% - 109px)",
       },
+      options: [{
+        value: 0,
+        label: '鏅�氱敤鎴�'
+      }, {
+        value: 1,
+        label: '瓒呯骇绠$悊鍛�'
+      }, {
+        value: 2,
+        label: '鏁版嵁绠$悊鍛�'
+      }, {
+        value: 3,
+        label: '棰嗗'
+      }]
     };
   },
   methods: {
@@ -916,7 +951,7 @@
     },
     async handleEdit(index, row) {
       this.updateform = row;
-      this.updateform.isAdmin = row.isAdmin.toString();
+      // this.updateform.isAdmin = row.isAdmin.toString();
       const data = await selectDep({ id: row.depid });
       if (data.result == null) {
         this.updateform.depValue = null;

--
Gitblit v1.9.3