保安监管系统-验收版本
zhengpz
2021-09-17 363960a705971e84ac1a75cd3b95eb4a98c4ffd8
统计部份的弹表
7 files modified
2 files added
836 ■■■■■ changed files
src/api/statisticalQueryManagement/statisticalQueryManagement.js 18 ●●●●● patch | view | raw | blame | history
src/styles/common.scss 7 ●●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/businessStatistics.vue 75 ●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/businessStatisticsDetail.vue 1 ●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/businessStatisticsFwdq.vue 275 ●●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/businessStatisticsPq.vue 301 ●●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/companyDetails.vue 37 ●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/securityGuardDetail.vue 41 ●●●●● patch | view | raw | blame | history
src/views/statisticalQueryManagement/securityGuardStatistics.vue 81 ●●●● patch | view | raw | blame | history
src/api/statisticalQueryManagement/statisticalQueryManagement.js
@@ -69,3 +69,21 @@
    params: params
  });
};
// 派遣人员清单
export const dispatcher = params => {
  return request({
    url: "/api/dispatcher/page?dispatch=0",
    method: "get",
    params: params
  });
};
// 服务到期公司清单
export const dispatcherUnit2 = params => {
  return request({
    url: "/api/dispatcherUnit/page?isExpire=2",
    method: "get",
    params: params
  });
};
src/styles/common.scss
@@ -63,3 +63,10 @@
  }
}
// 统计弹表的样式
.tongji-class .el-dialog{
  width: 80%;
  margin-top: 10vh;
}
src/views/statisticalQueryManagement/businessStatistics.vue
@@ -23,12 +23,29 @@
      </avue-crud>
    </basic-container>
    <el-dialog
      class="fuwu-class"
      class="tongji-class"
      :title="dialogTitle"
      append-to-body
      :visible.sync="dialogShow"
      v-if="dialogShow"
    >
      <businessStatisticsDetail :fwdeptId="fwdeptId"></businessStatisticsDetail>
      <businessStatisticsDetail
        v-if="searchitem === 'fw'"
        :fwdeptId="fwdeptId"
      ></businessStatisticsDetail>
      <businessStatisticsPq
        v-if="searchitem === 'pq'"
        :fwdeptId="fwdeptId"
      ></businessStatisticsPq>
      <businessStatisticsFwdq
        v-if="searchitem === 'dq'"
        :fwdeptId="fwdeptId"
      ></businessStatisticsFwdq>
      <securityGuardDetail
        v-if="searchitem === 'zong'"
        :fwdeptId="fwdeptId"
        :paramCz="paramCz"
      ></securityGuardDetail>
      <!-- <avue-crud
        :option="option2"
        :data="data2"
@@ -53,10 +70,16 @@
} from "../../api/statisticalQueryManagement/statisticalQueryManagement";
import { lazyTreeJu, lazyTrees } from "../../api/index/index";
import businessStatisticsDetail from "./businessStatisticsDetail";
import businessStatisticsPq from "./businessStatisticsPq";
import businessStatisticsFwdq from "./businessStatisticsFwdq";
import securityGuardDetail from "./securityGuardDetail";
export default {
  name: "业务情况统计",
  components: {
    businessStatisticsDetail
    businessStatisticsDetail,
    businessStatisticsPq,
    businessStatisticsFwdq,
    securityGuardDetail
  },
  data() {
    return {
@@ -162,7 +185,10 @@
      loading: true,
      dialogTitle: "",
      dialogShow: false,
      fwdeptId: ""
      pqdialogShow: false,
      fwdeptId: "",
      searchitem: "",
      paramCz: false
    };
  },
  computed: {
@@ -239,9 +265,14 @@
      });
    },
    handleRowClick(row, column, cell, event) {
      this.dialogShow = true;
      this.paramCz = false;
      if (column.label == "服务对象数量") {
        this.dialogTitle = "业务统计明细---服务对象清单";
        this.searchitem = "fw";
        this.fwdeptId = row.departmentid;
        this.dialogShow = true;
        // dispatcherUnit({
        //   deptId: row.departmentid
        // }).then(res => {
@@ -260,11 +291,34 @@
        //     row.departmentid
        // });
      } else if (column.label == "保安员人数") {
        this.$router.push({
          path:
            "/statisticalQueryManagement/securityGuardDetail?departmentid=" +
            row.departmentid
        });
        this.dialogTitle = "业务统计明细---保安员清单";
        this.searchitem = "zong";
        this.fwdeptId = row.departmentid;
        this.dialogShow = true;
        // this.$router.push({
        //   path:
        //     "/statisticalQueryManagement/securityGuardDetail?departmentid=" +
        //     row.departmentid
        // });
      } else if (column.label == "派遣人数") {
        this.dialogTitle = "业务统计明细---派遣人员清单";
        this.searchitem = "pq";
        this.fwdeptId = row.departmentid;
        this.dialogShow = true;
      } else if (column.label == "服务到期数量") {
        this.dialogTitle = "业务统计明细---服务到期公司清单";
        this.searchitem = "dq";
        this.fwdeptId = row.departmentid;
        this.dialogShow = true;
      } else if (column.label == "持证人数") {
        this.dialogTitle = "业务统计明细---持证保安人员清单";
        this.searchitem = "dq";
        this.paramCz = true;
        this.fwdeptId = row.departmentid;
        this.dialogShow = true;
      } else {
        this.dialogShow = false;
      }
    }
  },
@@ -282,5 +336,4 @@
/deep/ .businessStatisticsStyle .el-table__row:hover td:nth-child(10) {
  cursor: pointer !important;
}
</style>
src/views/statisticalQueryManagement/businessStatisticsDetail.vue
@@ -98,6 +98,7 @@
          {
            label: "服务单位名称",
            prop: "name",
            width: 300,
            props: {
              label: "name",
              value: "name"
src/views/statisticalQueryManagement/businessStatisticsFwdq.vue
New file
@@ -0,0 +1,275 @@
<template>
  <basic-container>
    <avue-crud
      :option="tableOption"
      :table-loading="loading"
      :data="tableData"
      :page.sync="page"
      :permission="permissionList"
      ref="crud"
      @row-update="rowUpdates"
      @row-save="rowSave"
      @search-change="searchChange"
      @search-reset="searchReset"
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
    >
    </avue-crud>
  </basic-container>
</template>
<script>
import { mapGetters } from "vuex";
import {
  selectDis,
  selectFw,
  fwList,
  dispatcherUnit,
  dispatcherUnit2
} from "../../api/statisticalQueryManagement/statisticalQueryManagement";
import { lazyTreeJu, lazyTrees } from "../../api/index/index";
export default {
  name: "业务情况统计明细---保安公司服务到期的公司列表",
  props: ["fwdeptId"],
  data() {
    return {
      page: {
        pageSize: 10,
        currentPage: 1,
        total: 0
      },
      query: {},
      value1: "",
      value2: "",
      // tableData: [],
      tablePage: {
        pageSize: 10,
        currentPage: 1,
        total: 0
      },
      tableOption: {
        excelBtn: true,
        delBtn: false,
        editBtn: false,
        addBtn: false,
        selection: true,
        menu: false,
        // dateBtn: true,
        align: "center",
        height: "auto",
        calcHeight: 30,
        tip: false,
        searchShowBtn: false,
        searchShow: true,
        searchMenuSpan: 6,
        index: true,
        viewBtn: true,
        dialogClickModal: false,
        column: [
          {
            label: "服务单位名称",
            prop: "name",
            width: 300,
            props: {
              label: "name",
              value: "name"
            },
            dicData: [],
            searchLabelWidth: 110,
            search: true,
            type: "tree",
            searchSpan: 8,
            rules: [
              {
                required: true,
                message: "请选择服务单位",
                trigger: "blur"
              }
            ]
            // display: false
          },
          {
            label: "所属保安公司",
            prop: "tenantName",
            width: 300,
            display: false
          },
          {
            label: "服务开始时间",
            prop: "startTime",
            display: false
          },
          {
            label: "服务到期时间",
            prop: "endTime",
            display: false
          },
          {
            label: "保安员姓名",
            prop: "realName",
            display: false
          },
          {
            label: "联系人",
            prop: "linkman",
            display: false
          },
          {
            label: "联系电话",
            prop: "phone",
            display: false
          }
        ]
      },
      typeValue: "0",
      typeOptions: [
        {
          value: "0",
          label: "全部"
        },
        {
          value: "1",
          label: "社保缴纳人数"
        },
        {
          value: "2",
          label: "社保缴纳总额"
        },
        {
          value: "3",
          label: "公司派遣人数"
        },
        {
          value: "4",
          label: "社保缴纳人数占比"
        }
      ],
      subofficeValue: "0",
      subofficeOptions: [
        {
          value: "0",
          label: "南昌市公安局"
        },
        {
          value: "2",
          label: "东湖分局"
        },
        {
          value: "3",
          label: "西湖分局"
        },
        {
          value: "4",
          label: "青云谱分局"
        },
        {
          value: "5",
          label: "青山湖分局"
        }
      ],
      servicesList: [],
      companyName: "",
      loading: true,
      deptid: ""
    };
  },
  computed: {
    ...mapGetters(["permission"]),
    permissionList() {
      return {
        addBtn: this.vaildData(this.permission.post_add, false),
        viewBtn: this.vaildData(this.permission.post_view, false),
        delBtn: this.vaildData(this.permission.post_delete, false),
        editBtn: this.vaildData(this.permission.post_edit, false)
      };
    }
  },
  methods: {
    searchChange(params, done) {
      this.query = params;
      this.page.currentPage = 1;
      this.onLoad(this.page, params);
      done();
    },
    searchReset() {
      this.query = {};
      this.onLoad(this.page);
    },
    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);
    },
    onLoad(page, params = {}) {
      this.loading = true;
      let param = {};
      // param["jurisdiction"] = params["jurname"] || "";
      // param["id"] = params["name"] || "";
      param["deptId"] = this.fwdeptId;
      param["current"] = page.currentPage;
      param["size"] = page.pageSize;
      param["name"] = params["name"] || "";
      dispatcherUnit2(param).then(res => {
        const data = res.data.data;
        this.page.total = data.total;
        this.tableData = data.records;
        this.loading = false;
      });
    },
    getFuWuList() {
      selectFw().then(res => {
        if (res.data.code === 200) {
          this.tableOption.column.forEach(item => {
            if (item.label == "服务单位名称") {
              item.dicData = res.data.data;
            }
          });
          // this.servicesList = res.data.data;
        }
      });
    },
    getSubOfficeData() {
      lazyTrees().then(res => {
        if (res.data.code === 200) {
          this.tableOption.column.forEach(item => {
            if (item.label == "所属辖区") {
              item.dicData = res.data.data;
            }
          });
        } else {
          this.$message.error(res.msg);
        }
      });
    },
    getLocationParams() {
      let url = window.location.href;
      let urlArr = url.split("?")[1].split("&");
      var object = new Object();
      for (var i = 0; i < urlArr.length; i++) {
        let mm = urlArr[i].split("=");
        object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
      }
      this.deptid = object["departmentid"] || "";
      // let jurisdiction = object["jurisdiction"] || "";
      this.query = { deptid: this.deptid };
      // this.onLoad(this.page, obj);
      this.onLoad(this.page, this.query);
    }
  },
  mounted() {
    // this.getTableData();
    this.getFuWuList();
    this.getSubOfficeData();
    // this.getLocationParams();
  }
};
</script>
<style lang="scss" scoped></style>
src/views/statisticalQueryManagement/businessStatisticsPq.vue
New file
@@ -0,0 +1,301 @@
<template>
  <basic-container>
    <avue-crud
      :option="tableOption"
      :table-loading="loading"
      :data="tableData"
      :page.sync="page"
      :permission="permissionList"
      ref="crud"
      @row-update="rowUpdates"
      @row-save="rowSave"
      @search-change="searchChange"
      @search-reset="searchReset"
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
    >
    </avue-crud>
  </basic-container>
</template>
<script>
import { mapGetters } from "vuex";
import {
  selectDis,
  selectFw,
  fwList,
  dispatcherUnit,
  dispatcher
} from "../../api/statisticalQueryManagement/statisticalQueryManagement";
import { lazyTreeJu, lazyTrees } from "../../api/index/index";
export default {
  name: "业务情况统计明细",
  props: ["fwdeptId"],
  data() {
    return {
      page: {
        pageSize: 10,
        currentPage: 1,
        total: 0
      },
      query: {},
      value1: "",
      value2: "",
      // tableData: [],
      tablePage: {
        pageSize: 10,
        currentPage: 1,
        total: 0
      },
      tableOption: {
        excelBtn: true,
        delBtn: false,
        editBtn: false,
        addBtn: false,
        selection: true,
        menu: false,
        // dateBtn: true,
        align: "center",
        height: "auto",
        calcHeight: 30,
        tip: false,
        searchShowBtn: false,
        searchShow: true,
        searchMenuSpan: 6,
        index: true,
        viewBtn: true,
        dialogClickModal: false,
        column: [
          // {
          //   label: "公司名称",
          //   prop: "gsname",
          //   // search: true,
          //   // searchSpan: 4,
          //   display: false
          // },
          // {
          //   label: "所属辖区",
          //   prop: "jurname",
          //   searchSpan: 4,
          //   props: {
          //     label: "title",
          //     value: "id"
          //   },
          //   // cascaderItem: ["city", "area"],
          //   // dicUrl:subofficeOptions,
          //   dicData: [],
          //   search: true,
          //   type: "tree",
          //   rules: [
          //     {
          //       required: true,
          //       message: "请选择所属辖区",
          //       trigger: "blur"
          //     }
          //   ]
          // },
          {
            label: "保安公司名称",
            prop: "dispatcherCompany",
            width: 300,
            display: false
          },
          {
            label: "服务单位名称",
            prop: "deptName",
            width: 300,
            props: {
              label: "name",
              value: "name"
            },
            dicData: [],
            searchLabelWidth: 110,
            search: true,
            type: "tree",
            searchSpan: 8,
            rules: [
              {
                required: true,
                message: "请选择服务单位",
                trigger: "blur"
              }
            ]
            // display: false
          },
          {
            label: "派遣时间",
            prop: "dispatchertime",
            display: false
          },
          {
            label: "保安员姓名",
            prop: "realName",
            display: false
          },
          {
            label: "身份证号",
            prop: "idCardNo",
            display: false
          },
          {
            label: "联系电话",
            prop: "securityPhone",
            display: false
          }
        ]
      },
      typeValue: "0",
      typeOptions: [
        {
          value: "0",
          label: "全部"
        },
        {
          value: "1",
          label: "社保缴纳人数"
        },
        {
          value: "2",
          label: "社保缴纳总额"
        },
        {
          value: "3",
          label: "公司派遣人数"
        },
        {
          value: "4",
          label: "社保缴纳人数占比"
        }
      ],
      subofficeValue: "0",
      subofficeOptions: [
        {
          value: "0",
          label: "南昌市公安局"
        },
        {
          value: "2",
          label: "东湖分局"
        },
        {
          value: "3",
          label: "西湖分局"
        },
        {
          value: "4",
          label: "青云谱分局"
        },
        {
          value: "5",
          label: "青山湖分局"
        }
      ],
      servicesList: [],
      companyName: "",
      loading: true,
      deptid: ""
    };
  },
  computed: {
    ...mapGetters(["permission"]),
    permissionList() {
      return {
        addBtn: this.vaildData(this.permission.post_add, false),
        viewBtn: this.vaildData(this.permission.post_view, false),
        delBtn: this.vaildData(this.permission.post_delete, false),
        editBtn: this.vaildData(this.permission.post_edit, false)
      };
    }
  },
  methods: {
    searchChange(params, done) {
      this.query = params;
      this.page.currentPage = 1;
      this.onLoad(this.page, params);
      done();
    },
    searchReset() {
      this.query = {};
      this.onLoad(this.page);
    },
    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);
    },
    onLoad(page, params = {}) {
      debugger;
      this.loading = true;
      let param = {};
      // param["jurisdiction"] = params["jurname"] || "";
      // param["id"] = params["name"] || "";
      param["deptId"] = this.fwdeptId;
      param["current"] = page.currentPage;
      param["size"] = page.pageSize;
      param["dispatcherCompany"] = params["name"] || "";
      dispatcher(param).then(res => {
        const data = res.data.data;
        this.page.total = data.total;
        this.tableData = data.records;
        this.loading = false;
      });
    },
    getFuWuList() {
      selectFw().then(res => {
        if (res.data.code === 200) {
          this.tableOption.column.forEach(item => {
            if (item.label == "服务单位名称") {
              item.dicData = res.data.data;
            }
          });
          // this.servicesList = res.data.data;
        }
      });
    },
    getSubOfficeData() {
      lazyTrees().then(res => {
        if (res.data.code === 200) {
          this.tableOption.column.forEach(item => {
            if (item.label == "所属辖区") {
              item.dicData = res.data.data;
            }
          });
        } else {
          this.$message.error(res.msg);
        }
      });
    },
    getLocationParams() {
      let url = window.location.href;
      let urlArr = url.split("?")[1].split("&");
      var object = new Object();
      for (var i = 0; i < urlArr.length; i++) {
        let mm = urlArr[i].split("=");
        object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
      }
      this.deptid = object["departmentid"] || "";
      // let jurisdiction = object["jurisdiction"] || "";
      this.query = { deptid: this.deptid };
      // this.onLoad(this.page, obj);
      this.onLoad(this.page, this.query);
    }
  },
  mounted() {
    // this.getTableData();
    this.getFuWuList();
    this.getSubOfficeData();
    // this.getLocationParams();
  }
};
</script>
<style lang="scss" scoped></style>
src/views/statisticalQueryManagement/companyDetails.vue
@@ -12,6 +12,7 @@
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
    >
    </avue-crud>
  </basic-container>
@@ -23,6 +24,7 @@
import { selectUIn } from "../../api/statisticalQueryManagement/statisticalQueryManagement";
export default {
  name: "公司人员详情",
  props: ["fwdeptId"],
  data() {
    return {
      page: {
@@ -85,7 +87,7 @@
        tip: false,
        searchShowBtn: false,
        searchShow: true,
        searchMenuSpan: 3,
        searchMenuSpan: 10,
        index: true,
        viewBtn: true,
        dialogClickModal: false,
@@ -95,7 +97,7 @@
            // searchLabelWidth: 90,
            prop: "real_name",
            search: true,
            searchSpan: 3,
            searchSpan: 4,
            display: false
          },
          {
@@ -126,7 +128,7 @@
          {
            label: "是否持证",
            prop: "hold",
            searchSpan: 3,
            searchSpan: 4,
            type: "select",
            props: {
              label: "label",
@@ -278,7 +280,7 @@
          {
            label: "是否派遣",
            prop: "dispatch",
            searchSpan: 3,
            searchSpan: 4,
            type: "select",
            props: {
              label: "label",
@@ -345,12 +347,13 @@
      this.onLoad(this.page, this.query);
    },
    onLoad(page, params = {}) {
      debugger
      this.loading = true;
      // if (!params) {
      //   params = { current: page.currentPage, size: page.pageSize };
      // }
      let param = {};
      param["deptid"] = this.deptid;
      param["deptid"] = this.fwdeptId;
      param["name"] = params["real_name"] || "";
      param["hold"] =
        params["hold"] || params["hold"] == "0" ? Number(params["hold"]) : "";
@@ -379,18 +382,18 @@
      });
    },
    getLocationParams() {
      let url = window.location.href;
      let urlArr = url.split("?")[1].split("&");
      var object = new Object();
      for (var i = 0; i < urlArr.length; i++) {
        let mm = urlArr[i].split("=");
        object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
      }
      this.deptid = object["deptid"] || "";
      this.query = { deptid: this.deptid };
      this.onLoad(this.page, this.query);
    }
    // getLocationParams() {
    //   let url = window.location.href;
    //   let urlArr = url.split("?")[1].split("&");
    //   var object = new Object();
    //   for (var i = 0; i < urlArr.length; i++) {
    //     let mm = urlArr[i].split("=");
    //     object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
    //   }
    //   this.deptid = object["deptid"] || "";
    //   this.query = { deptid: this.deptid };
    //   this.onLoad(this.page, this.query);
    // }
  },
  mounted() {
    // this.getTableData();
src/views/statisticalQueryManagement/securityGuardDetail.vue
@@ -15,6 +15,7 @@
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @row-click="handleRowClick"
      @on-load="onLoad"
    >
    </avue-crud>
  </basic-container>
@@ -22,8 +23,10 @@
<script>
import { mapGetters } from "vuex";
import { pageSecurity } from "../../api/statisticalQueryManagement/statisticalQueryManagement";
export default {
  name: "保安员明细",
  props: ["fwdeptId", "paramCz"],
  data() {
    return {
      page: {
@@ -211,7 +214,7 @@
              }
            ],
            slot: true,
            display: false,
            display: false
          },
          {
            label: "是否持证",
@@ -234,7 +237,7 @@
              }
            ],
            slot: true,
            display: false,
            display: false
          }
        ]
      },
@@ -283,8 +286,12 @@
      let param = {};
      param["realName"] = params["realName"] || "";
      param["status"] = params["status"] || "";
      param["deptId"] = this.deptid;
      param["hold"] = params["hold"] || "";
      param["deptId"] = this.fwdeptId;
      if (this.paramCz) {
        param["hold"] = "0";
      } else {
        param["hold"] = params["hold"] || "";
      }
      param["current"] = page.currentPage;
      param["size"] = page.pageSize;
      pageSecurity(param).then(res => {
@@ -293,20 +300,20 @@
        this.data = data.records;
        this.loading = false;
      });
    },
    getLocationParams() {
      let url = window.location.href;
      let urlArr = url.split("?")[1].split("&");
      var object = new Object();
      for (var i = 0; i < urlArr.length; i++) {
        let mm = urlArr[i].split("=");
        object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
      }
      this.deptid = object["departmentid"] || "";
      this.query = { deptid: this.deptid };
      this.onLoad(this.page, this.query);
      //   this.onLoad(this.page, this.query);
    }
    // getLocationParams() {
    //   let url = window.location.href;
    //   let urlArr = url.split("?")[1].split("&");
    //   var object = new Object();
    //   for (var i = 0; i < urlArr.length; i++) {
    //     let mm = urlArr[i].split("=");
    //     object[decodeURIComponent(mm[0])] = decodeURIComponent(mm[1]);
    //   }
    //   this.deptid = object["departmentid"] || "";
    //   this.query = { deptid: this.deptid };
    //   this.onLoad(this.page, this.query);
    //   //   this.onLoad(this.page, this.query);
    // }
  },
  mounted() {
    this.getLocationParams();
src/views/statisticalQueryManagement/securityGuardStatistics.vue
@@ -1,23 +1,44 @@
<template>
  <basic-container>
    <avue-crud
      :option="tableOption"
      :table-loading="loading"
      :data="tableData"
      :page.sync="page"
      :permission="permissionList"
      ref="crud"
      @search-change="searchChange"
      @search-reset="searchReset"
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      @on-load="onLoad"
      @row-click="handleRowClick"
      class="rowClick"
  <div>
    <basic-container>
      <avue-crud
        :option="tableOption"
        :table-loading="loading"
        :data="tableData"
        :page.sync="page"
        :permission="permissionList"
        ref="crud"
        @search-change="searchChange"
        @search-reset="searchReset"
        @current-change="currentChange"
        @size-change="sizeChange"
        @refresh-change="refreshChange"
        @on-load="onLoad"
        @cell-click="handleRowClick"
        class="rowClick"
      >
      </avue-crud>
    </basic-container>
    <el-dialog
      class="tongji-class"
      :title="dialogTitle"
      append-to-body
      :visible.sync="dialogShow"
      v-if="dialogShow"
    >
    </avue-crud>
  </basic-container>
      <companyDetails :fwdeptId="fwdeptId"></companyDetails>
      <!-- <avue-crud
        :option="option2"
        :data="data2"
        :page.sync="page2"
        @row-save="rowSave2"
        @row-update="rowUpdate2"
        @row-del="rowDel2"
        :table-loading="loading2"
      >
      </avue-crud> -->
    </el-dialog>
  </div>
</template>
<script>
import FileSaver from "file-saver";
@@ -28,8 +49,12 @@
  dictionaryList
} from "../../api/statisticalQueryManagement/statisticalQueryManagement";
import { lazyTreeJu, lazyTrees } from "../../api/index/index";
import companyDetails from "./companyDetails";
export default {
  name: "业务情况统计",
  components: {
    companyDetails
  },
  data() {
    return {
      page: {
@@ -156,7 +181,8 @@
        ]
      },
      companyName: "",
      loading: true
      loading: true,
      dialogShow: false
    };
  },
  computed: {
@@ -243,10 +269,17 @@
        this.loading = false;
      });
    },
    handleRowClick(row, event, column) {
      this.$router.push({
        path: "/statisticalQueryManagement/companyDetails?deptid=" + row.dept_id
      });
    handleRowClick(row, column, cell, event) {
      if (column.label == "保安员总数") {
        this.dialogTitle = "保安员明细";
        this.fwdeptId = row.dept_id;
        this.dialogShow = true;
      } else {
        this.dialogShow = false;
      }
      // this.$router.push({
      //   path: "/statisticalQueryManagement/companyDetails?deptid=" + row.dept_id
      // });
    }
  },
  mounted() {
@@ -256,7 +289,7 @@
};
</script>
<style lang="scss" scoped>
/deep/ .rowClick .el-table__row:hover td {
/deep/ .rowClick .el-table__row:hover td:nth-child(6) {
  cursor: pointer;
}
</style>