Administrator
2021-08-07 bc3f630d4cdbaad3cd4620cc01fd6f693f07dfcd
src/views/securityUnit/index.vue
@@ -16,6 +16,15 @@
      @refresh-change="refreshChange"
      @row-click="rowClick"
    >
      <template slot-scope="{ type, size, row }" slot="menu">
        <el-button
          :size="size"
          :type="type"
          @click="handleUploadPage(row)"
          icon="el-icon-circle-check"
          >单位装备清单附件上传
        </el-button>
      </template>
      <template slot="menuLeft">
        <el-button
          type="primary"
@@ -103,6 +112,7 @@
  adddata2,
  getDeptLazyTree,
} from "@/api/securityUnit/securityUnit";
import { mapGetters } from "vuex";
export default {
  data() {
    var w = 160,
@@ -212,13 +222,14 @@
      query: {},
      data: [],
      option: {
        index: true,
        addBtn: false,
        // card: true,
        tip: false,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 623,
        menuWidth: 160,
        height: 693,
        menuWidth: 290,
        align: "center",
        selection: true,
        column: column,
@@ -226,6 +237,7 @@
    };
  },
  computed: {
    ...mapGetters(["userInfo"]),
    ids() {
      let ids = [];
      this.selectionList.forEach((ele) => {
@@ -331,7 +343,7 @@
      })
        .then(() => {
          console.log(row);
          return remove(row.creditcode);
          return remove(row.creditcode, row.departmentid);
        })
        .then(() => {
          this.onLoad(this.page);
@@ -355,8 +367,8 @@
        type: "warning",
      })
        .then(() => {
          // console.log(this.ids);
          return remove(this.ids);
          console.log(this.ids);
          // return remove(this.ids);
        })
        .then(() => {
          this.onLoad(this.page);
@@ -381,7 +393,21 @@
        // params: { row: row.identificationnumber },
      });
    },
    //跳转到附近列表页面
    handleUploadPage(row) {
      this.$router.push({
        path: `/resource/attachCopy`,
        query: {
          deptId: row.departmentid,
          enterprisename: row.enterprisename,
        },
      });
    },
    onLoad(page, params = {}) {
      if (this.userInfo.role_id == "1414840172333842433") {
        console.log("是公安add jurisdiction");
        params["jurisdiction"] = this.userInfo.jurisdiction;
      }
      this.loading = true;
      getdata(
        page.currentPage,
@@ -421,7 +447,7 @@
          }
        }
      }
      // console.log(d);
      console.log(d);
      for (var k in d) {
        if (d[k] == "" || d[k] == undefined) {
          console.log(k);
@@ -506,10 +532,8 @@
      });
      var time = setTimeout(() => {
        this.onLoad(this.page, this.query);
        clearTimeout(time);
        time = null;
        console.log(this.data0, this.data1, this.data2, "已刷新");
      }, 500);
      console.log(this.data0, this.data1, this.data2);
      this.tipover();
    },
    tip1up1() {