liutao před 2 dny
rodič
revize
94a3494e14

+ 1 - 0
YHYZT/client/public/config.js

@@ -1,6 +1,7 @@
 window.ApplicationConfig = {
   baseUrl: "http://localhost:5566/yzt/",
   tokenKey: 'ZJUGIS-Authorization',
+  arcgisQueryToken: 'Ddf8wy1xj3AKB7viZeXnv7-xg9efyhBNgC11LDVFmk-0OUITT_YU3NRFOKSbhtlR',
   validateURL: "http://localhost:5566/yzt/api/user/validate",
   previewPrefix: 'http://localhost:5566/yzt',
   zhmhUrl: 'http://localhost:8088/#/yh-yzt/data-center',

+ 12 - 0
YHYZT/client/src/utils/arcgis-map-server-query.js

@@ -53,6 +53,18 @@ import { EsriJSON } from 'ol/format'
  * @returns {Promise<ResponseS>}
  */
 export function arcgisQuery(url, param, toFeature = false) {
+  // 从全局配置获取token
+  let token = null
+  if (typeof window !== 'undefined' && window.ApplicationConfig && window.ApplicationConfig.arcgisQueryToken) {
+    token = window.ApplicationConfig.arcgisQueryToken
+  }
+  if (token) {
+    if (url.indexOf('?') > -1) {
+      url += `&token=${token}`
+    } else {
+      url += `?token=${token}`
+    }
+  }
   const _default = {
     where: '1=1',
     text: '',

+ 31 - 22
YHYZT/client/src/views/DataManage/Gd.vue

@@ -53,28 +53,22 @@
             <el-col :span="6">
               <div class="btn-group" style="margin-left: 20px;">
                 <el-button type="primary" @click="onSearchHandle">查询</el-button>
-                <div class="panel-dropdown">
-                  <el-dropdown>
-                    <el-button type="success">
-                      导入文件<i class="el-icon-arrow-down el-icon--right"></i>
-                    </el-button>
-                    <el-dropdown-menu slot="dropdown">
-                      <el-dropdown-item>
-                        <el-upload
-                            class="upload-demo"
-                            action=""
-                            :before-upload="beforeUpload"
-                            multiple
-                            :limit="3"
-                            :on-exceed="2"
-                            accept=".zip">
-                        批量导入&nbsp;&nbsp;
-                        </el-upload>
-                      </el-dropdown-item>
-                    </el-dropdown-menu>
-                  </el-dropdown>
-                </div>
-                <el-button type="primary" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
+                <el-button type="info" @click="resetSearch">清空</el-button>
+                <el-upload
+                  class="upload-demo"
+                  action=""
+                  :before-upload="beforeUpload"
+                  multiple
+                  :limit="3"
+                  :on-exceed="2"
+                  accept=".zip"
+                  style="display:inline-block; margin-left: 10px;"
+                >
+                  <el-button type="success">
+                    导入文件
+                  </el-button>
+                </el-upload>
+                <el-button type="warning" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
               </div>
             </el-col>
           </el-row>
@@ -339,6 +333,21 @@ export default {
     downloadTemplate() {
       // 模板下载地址
       window.open(window.ApplicationConfig.templateUrls.gd);
+    },
+    resetSearch() {
+      this.searchParam = {
+        gdsy: '',
+        dkMc: '',
+        djklx: '',
+        dkMjMin: '',
+        dkMjMax: '',
+        dkBh: '',
+        dkYt: '',
+        dwMc: '',
+        htydpzbh: '',
+        current: 1,
+        size: 10
+      };
     }
   }
 }

+ 32 - 22
YHYZT/client/src/views/DataManage/Lsyd.vue

@@ -54,28 +54,22 @@
             <el-col :span="6">
               <div class="btn-group">
                 <el-button type="primary" @click="onSearchHandle">查询</el-button>
-                <div class="panel-dropdown">
-                  <el-dropdown>
-                    <el-button type="success">
-                      导入文件<i class="el-icon-arrow-down el-icon--right"></i>
-                    </el-button>
-                    <el-dropdown-menu slot="dropdown">
-                      <el-dropdown-item>
-                        <el-upload
-                            class="upload-demo"
-                            action=""
-                            :before-upload="beforeUpload"
-                            multiple
-                            :limit="3"
-                            :on-exceed="2"
-                            accept=".zip">
-                        批量导入&nbsp;&nbsp;
-                        </el-upload>
-                      </el-dropdown-item>
-                    </el-dropdown-menu>
-                  </el-dropdown>
-                </div>
-                <el-button type="primary" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
+                <el-button type="info" style="margin-left: 8px;" @click="onResetHandle">清空</el-button>
+                <el-upload
+                  class="upload-demo"
+                  action=""
+                  :before-upload="beforeUpload"
+                  multiple
+                  :limit="3"
+                  :on-exceed="2"
+                  accept=".zip"
+                  style="display:inline-block; margin-left: 10px;"
+                >
+                  <el-button type="success">
+                    导入文件
+                  </el-button>
+                </el-upload>
+                <el-button type="warning" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
               </div>
             </el-col>
           </el-row>
@@ -313,6 +307,22 @@ export default {
     downloadTemplate() {
       // 模板下载地址
       window.open(window.ApplicationConfig.templateUrls.lsyd);
+    },
+    onResetHandle() {
+      this.searchParam = {
+        xmmc: '',
+        pzwh: '',
+        yddw: '',
+        pzmj: '',
+        pzdw: '',
+        zlwz: '',
+        dqsjStart: '',
+        dqsjEnd: '',
+        current: 1,
+        size: 10
+      };
+      this.dqsjDateRange = [];
+      this.queryByPage();
     }
   }
 }

+ 31 - 22
YHYZT/client/src/views/DataManage/Nzy.vue

@@ -60,28 +60,22 @@
             <el-col :span="6">
               <div class="btn-group">
                 <el-button type="primary" @click="onSearchHandle">查询</el-button>
-                <div class="panel-dropdown">
-                  <el-dropdown>
-                    <el-button type="success">
-                      导入文件<i class="el-icon-arrow-down el-icon--right"></i>
-                    </el-button>
-                    <el-dropdown-menu slot="dropdown">
-                      <el-dropdown-item>
-                        <el-upload
-                            class="upload-demo"
-                            action=""
-                            :before-upload="beforeUpload"
-                            multiple
-                            :limit="3"
-                            :on-exceed="2"
-                            accept=".zip">
-                        批量导入&nbsp;&nbsp;
-                        </el-upload>
-                      </el-dropdown-item>
-                    </el-dropdown-menu>
-                  </el-dropdown>
-                </div>
-                <el-button type="primary" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
+                <el-button type="info" @click="onResetHandle">清空</el-button>
+                <el-upload
+                  class="upload-demo"
+                  action=""
+                  :before-upload="beforeUpload"
+                  multiple
+                  :limit="3"
+                  :on-exceed="2"
+                  accept=".zip"
+                  style="display:inline-block; margin-left: 10px;"
+                >
+                  <el-button type="success">
+                    导入文件
+                  </el-button>
+                </el-upload>
+                <el-button type="warning" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
               </div>
             </el-col>
           </el-row>
@@ -360,6 +354,21 @@ export default {
     downloadTemplate() {
       // 模板下载地址
       window.open(window.ApplicationConfig.templateUrls.nzy);
+    },
+    onResetHandle() {
+      this.searchParam = {
+        pcbh: '',
+        pch: '',
+        lx: '',
+        pwh: '',
+        pzrqStart: '',
+        pzrqEnd: '',
+        pzmj: '',
+        nmjf: '',
+        current: 1,
+        size: 10
+      };
+      this.pcrqDateRange = [];
     }
   }
 }

+ 10 - 0
YHYZT/client/src/views/DataManage/Pewg.vue

@@ -45,6 +45,7 @@
             <el-col :span="6">
               <div class="btn-group">
                 <el-button type="primary" @click="onSearchHandle">查询</el-button>
+                <el-button @click="onResetHandle" type="info" style="margin-left: 10px;">清空</el-button>
               </div>
             </el-col>
           </el-row>
@@ -223,6 +224,15 @@ export default {
       }
       return row.area;
     },
+    onResetHandle() {
+      this.searchParam.pcbh = '';
+      this.searchParam.dkMc = '';
+      this.searchParam.area = '';
+      this.searchParam.xzz = '';
+      this.searchParam.dkYt = '';
+      this.searchParam.lx = '';
+      this.searchParam.wgyy = '';
+    }
   }
 }
 </script>

+ 30 - 22
YHYZT/client/src/views/DataManage/Ssnyd.vue

@@ -53,28 +53,22 @@
             <el-col :span="6">
               <div class="btn-group">
                 <el-button type="primary" @click="onSearchHandle">查询</el-button>
-                <div class="panel-dropdown">
-                  <el-dropdown>
-                    <el-button type="success">
-                      导入文件<i class="el-icon-arrow-down el-icon--right"></i>
-                    </el-button>
-                    <el-dropdown-menu slot="dropdown">
-                      <el-dropdown-item>
-                        <el-upload
-                            class="upload-demo"
-                            action=""
-                            :before-upload="beforeUpload"
-                            multiple
-                            :limit="3"
-                            :on-exceed="2"
-                            accept=".zip">
-                        批量导入&nbsp;&nbsp;
-                        </el-upload>
-                      </el-dropdown-item>
-                    </el-dropdown-menu>
-                  </el-dropdown>
-                </div>
-                <el-button type="primary" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
+                <el-button type="info" style="margin-left: 8px;" @click="onResetHandle">清空</el-button>
+                <el-upload
+                  class="upload-demo"
+                  action=""
+                  :before-upload="beforeUpload"
+                  multiple
+                  :limit="3"
+                  :on-exceed="2"
+                  accept=".zip"
+                  style="display:inline-block; margin-left: 10px;"
+                >
+                  <el-button type="success">
+                    导入文件
+                  </el-button>
+                </el-upload>
+                <el-button type="warning" @click="downloadTemplate" style="margin-left: 12px">模板下载</el-button>
               </div>
             </el-col>
           </el-row>
@@ -328,6 +322,20 @@ export default {
     downloadTemplate() {
       // 模板下载地址
       window.open(window.ApplicationConfig.templateUrls.ssnyd);
+    },
+    onResetHandle() {
+      this.searchParam = {
+        xmbh: '',
+        ban: '',
+        yt: '',
+        xzq: '',
+        basjStart: '',
+        basjEnd: '',
+        current: 1,
+        size: 10
+      };
+      this.basjDateRange = [];
+      this.queryByPage();
     }
   }
 }