From 8cbb44a2182a992faeeb0c1fa08e64fb104ae75c Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Tue, 30 Nov 2021 14:30:18 +0800
Subject: [PATCH] 武装修改

---
 src/views/securityUnitOperation/operationTable.vue |   53 +++++++++++------------------------------------------
 1 files changed, 11 insertions(+), 42 deletions(-)

diff --git a/src/views/securityUnitOperation/operationTable.vue b/src/views/securityUnitOperation/operationTable.vue
index 43bcb26..94e4468 100644
--- a/src/views/securityUnitOperation/operationTable.vue
+++ b/src/views/securityUnitOperation/operationTable.vue
@@ -7,8 +7,6 @@
       :page.sync="page"
       :permission="permissionList"
       ref="crud"
-      @row-update="rowUpdates"
-      @row-save="rowSave"
       @search-change="searchChange"
       @search-reset="searchReset"
       @current-change="currentChange"
@@ -20,10 +18,8 @@
   </basic-container>
 </template>
 <script>
-import FileSaver from "file-saver";
-import XLSX from "xlsx";
 import { selectTb } from "../../api/securityUnitOperation/securityUnitOperation";
-import { lazyTreeJu } from "../../api/index/index";
+import { lazyTreeJu,lazyTrees } from "../../api/index/index";
 export default {
   name: "公司运营情况智能分析详情表",
   data() {
@@ -33,6 +29,7 @@
         currentPage: 1,
         total: 0
       },
+      query:{},
       value1: "",
       value2: "",
       tableData: [
@@ -92,6 +89,7 @@
         searchShow: true,
         searchMenuSpan: 6,
         index: true,
+        indexLabel:'序号',
         viewBtn: true,
         dialogClickModal: false,
         column: [
@@ -156,6 +154,7 @@
             prop: "enterpriseName",
             search: true,
             searchSpan: 4,
+            width:300,
             display: false
           },
           {
@@ -243,38 +242,6 @@
     };
   },
   methods: {
-    rowSave(row, done, loading) {
-      adddata(row).then(
-        () => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        },
-        error => {
-          window.console.log(error);
-          loading();
-        }
-      );
-    },
-    rowUpdates(row, index, done, loading) {
-      update(row).then(
-        () => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        },
-        error => {
-          window.console.log(error);
-          loading();
-        }
-      );
-    },
     searchChange(params, done) {
       this.query = params;
       this.page.currentPage = 1;
@@ -288,9 +255,11 @@
     },
     currentChange(currentPage) {
       this.page.currentPage = currentPage;
+      this.onLoad(this.page, this.query)
     },
     sizeChange(pageSize) {
       this.page.pageSize = pageSize;
+      this.onLoad(this.page, this.query)
     },
     refreshChange() {
       this.onLoad(this.page, this.query);
@@ -305,12 +274,12 @@
       selectTb(param).then(res => {
         const data = res.data.data;
         this.page.total = data.total;
-        this.tableData = res.data.data;
+        this.tableData = data.records;
         this.loading = false;
       });
     },
     getSubOfficeData() {
-      lazyTreeJu().then(res => {
+      lazyTrees().then(res => {
         if (res.data.code === 200) {
           this.tableOption.column.forEach(item => {
             if (item.label == "所属辖区") {
@@ -330,10 +299,10 @@
         let mm = urlArr[i].split("=");
         object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
       }
-      let jurisdiction = object["jurisdiction"] || "";
+      let jurisdiction = object["jurisdiction1"] || "";
       let enterpriseName = object["enterpriseName"] || "";
-      let obj = { jurisdiction: jurisdiction, enterpriseName: enterpriseName };
-      this.onLoad(this.page, obj);
+      this.query = { jurisdiction: jurisdiction, enterpriseName: enterpriseName };
+      this.onLoad(this.page, this.query);
     }
   },
   mounted() {

--
Gitblit v1.9.3