|  | @@ -0,0 +1,259 @@
 | 
											
												
													
														|  | 
 |  | +<template>
 | 
											
												
													
														|  | 
 |  | +    <div class="app-container">
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +          <el-form :model="queryParams" ref="queryForm" size="small"  :inline="true"
 | 
											
												
													
														|  | 
 |  | +          v-show="showSearch"
 | 
											
												
													
														|  | 
 |  | +          label-width="100px">
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +            <el-form-item label="组织机构" prop="orgId" class="formTreeItem">
 | 
											
												
													
														|  | 
 |  | +            <tree-select
 | 
											
												
													
														|  | 
 |  | +              v-model="queryParams.orgId"
 | 
											
												
													
														|  | 
 |  | +              :options="deptOptions"
 | 
											
												
													
														|  | 
 |  | +              :show-count="true"
 | 
											
												
													
														|  | 
 |  | +              :normalizer="tenantIdnormalizer"
 | 
											
												
													
														|  | 
 |  | +              :props="{ checkStrictly: true, label: 'name' }"
 | 
											
												
													
														|  | 
 |  | +              placeholder="请选择归属机构"
 | 
											
												
													
														|  | 
 |  | +              clearValueText="清除"
 | 
											
												
													
														|  | 
 |  | +              :noChildrenText="''"
 | 
											
												
													
														|  | 
 |  | +              noOptionsText="没有数据"
 | 
											
												
													
														|  | 
 |  | +              noResultsText="没有搜索结果"
 | 
											
												
													
														|  | 
 |  | +            />
 | 
											
												
													
														|  | 
 |  | +          </el-form-item>
 | 
											
												
													
														|  | 
 |  | +              <el-form-item label="时间" prop="searchTime">
 | 
											
												
													
														|  | 
 |  | +                <el-date-picker   value-format='yyyy-MM' v-model="queryParams.searchTime"
 | 
											
												
													
														|  | 
 |  | +                                align="right" type="date" placeholder="请选择查询时间">
 | 
											
												
													
														|  | 
 |  | +                </el-date-picker>
 | 
											
												
													
														|  | 
 |  | +              </el-form-item>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +              <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
 | 
											
												
													
														|  | 
 |  | +              <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
 | 
											
												
													
														|  | 
 |  | +            </el-form-item>
 | 
											
												
													
														|  | 
 |  | +          </el-form>
 | 
											
												
													
														|  | 
 |  | +          <h3 class="title">{{ this.title}}</h3>
 | 
											
												
													
														|  | 
 |  | +          <el-row :gutter="10" class="mb8">
 | 
											
												
													
														|  | 
 |  | +            <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
 | 
											
												
													
														|  | 
 |  | +          </el-row>
 | 
											
												
													
														|  | 
 |  | +          <el-table
 | 
											
												
													
														|  | 
 |  | +            border
 | 
											
												
													
														|  | 
 |  | +            height="700"
 | 
											
												
													
														|  | 
 |  | +            size="small"
 | 
											
												
													
														|  | 
 |  | +            v-loading="loading" :data="checkList" @selection-change="handleSelectionChange">
 | 
											
												
													
														|  | 
 |  | +       
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="序号" align="center" min-width="50">
 | 
											
												
													
														|  | 
 |  | +              <template v-slot:default="scope">
 | 
											
												
													
														|  | 
 |  | +                <span v-text="getPageIndex(scope.$index)"> </span>
 | 
											
												
													
														|  | 
 |  | +              </template>
 | 
											
												
													
														|  | 
 |  | +            </el-table-column>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="地区" align="center" prop="city" />
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="单位名称" align="center" prop="orgName" width="100"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="网点数量" align="left" prop="networkNumber" width="100"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="应履职次数" align="center" prop="planNumber"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="已履职次数" align="center" prop="realityNumber"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="履职完成率" align="center" prop="realityRate"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="隐患数量" align="center" prop="abnormalNumber"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="已整改数量" align="center" prop="realityRectificationNumber"/>
 | 
											
												
													
														|  | 
 |  | +            <el-table-column label="整改完成率" align="center" prop="realityRectificationRate"/>
 | 
											
												
													
														|  | 
 |  | +          </el-table>
 | 
											
												
													
														|  | 
 |  | +          <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
 | 
											
												
													
														|  | 
 |  | +                      :limit.sync="queryParams.pageSize"
 | 
											
												
													
														|  | 
 |  | +                      @pagination="getList"/>
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +    </div>
 | 
											
												
													
														|  | 
 |  | +  </template>
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +  <script>
 | 
											
												
													
														|  | 
 |  | +    import tableList from '@/mixins/tableList'
 | 
											
												
													
														|  | 
 |  | +    import {listIntrusionTestReport} from "@/api/core/reportForms/resumptionReport";
 | 
											
												
													
														|  | 
 |  | +    import treeselect from '@riophae/vue-treeselect'
 | 
											
												
													
														|  | 
 |  | +    import "@riophae/vue-treeselect/dist/vue-treeselect.css";
 | 
											
												
													
														|  | 
 |  | +    import {deptTreeSelect,businessTreeSelect} from "@/api/system/public";
 | 
											
												
													
														|  | 
 |  | +    import orgTree from "@/components/orgTree";
 | 
											
												
													
														|  | 
 |  | +    export default {
 | 
											
												
													
														|  | 
 |  | +      name: "Check",
 | 
											
												
													
														|  | 
 |  | +      /** 引入基础minxins*/
 | 
											
												
													
														|  | 
 |  | +      mixins: [tableList],
 | 
											
												
													
														|  | 
 |  | +      components: {treeselect,orgTree},
 | 
											
												
													
														|  | 
 |  | +      dicts: ['sys_normal_disable','sys_org_type','repot_cycle'],
 | 
											
												
													
														|  | 
 |  | +      data() {
 | 
											
												
													
														|  | 
 |  | +        return {
 | 
											
												
													
														|  | 
 |  | +            startDatepickerOptions: {
 | 
											
												
													
														|  | 
 |  | +        disabledDate(time) {
 | 
											
												
													
														|  | 
 |  | +          const date = new Date();
 | 
											
												
													
														|  | 
 |  | +          date.setTime(date.getTime());
 | 
											
												
													
														|  | 
 |  | +          return time.getTime() < date;
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +          // 遮罩层
 | 
											
												
													
														|  | 
 |  | +          loading: true,
 | 
											
												
													
														|  | 
 |  | +          // 选中数组
 | 
											
												
													
														|  | 
 |  | +          ids: [],
 | 
											
												
													
														|  | 
 |  | +          names: [],
 | 
											
												
													
														|  | 
 |  | +          // 非单个禁用
 | 
											
												
													
														|  | 
 |  | +          single: true,
 | 
											
												
													
														|  | 
 |  | +          //搜索tree
 | 
											
												
													
														|  | 
 |  | +          deptName: null,
 | 
											
												
													
														|  | 
 |  | +          // 非多个禁用
 | 
											
												
													
														|  | 
 |  | +          multiple: true,
 | 
											
												
													
														|  | 
 |  | +          // 显示搜索条件
 | 
											
												
													
														|  | 
 |  | +          showSearch: true,
 | 
											
												
													
														|  | 
 |  | +          //区域
 | 
											
												
													
														|  | 
 |  | +          roleOptions: [],
 | 
											
												
													
														|  | 
 |  | +           //全部检查机构
 | 
											
												
													
														|  | 
 |  | +      orgOptions: [],
 | 
											
												
													
														|  | 
 |  | +          //搜索tree
 | 
											
												
													
														|  | 
 |  | +          deptName: null,
 | 
											
												
													
														|  | 
 |  | +          // 部门树选项
 | 
											
												
													
														|  | 
 |  | +          deptOptions: [],
 | 
											
												
													
														|  | 
 |  | +          // 总条数
 | 
											
												
													
														|  | 
 |  | +          total: 0,
 | 
											
												
													
														|  | 
 |  | +          //区域集合
 | 
											
												
													
														|  | 
 |  | +          areaList: [],
 | 
											
												
													
														|  | 
 |  | +          // 区域采集点表格数据
 | 
											
												
													
														|  | 
 |  | +          checkList: [],
 | 
											
												
													
														|  | 
 |  | +          // 弹出层标题
 | 
											
												
													
														|  | 
 |  | +          title: "",
 | 
											
												
													
														|  | 
 |  | +          // 是否显示弹出层
 | 
											
												
													
														|  | 
 |  | +          open: false,
 | 
											
												
													
														|  | 
 |  | +          // 查询参数
 | 
											
												
													
														|  | 
 |  | +          queryParams: {
 | 
											
												
													
														|  | 
 |  | +            pageNum: 1,
 | 
											
												
													
														|  | 
 |  | +            pageSize: 10,
 | 
											
												
													
														|  | 
 |  | +            checkName: null,
 | 
											
												
													
														|  | 
 |  | +            areaId: null,
 | 
											
												
													
														|  | 
 |  | +            orgId: null,
 | 
											
												
													
														|  | 
 |  | +            searchTime:null
 | 
											
												
													
														|  | 
 |  | +          },
 | 
											
												
													
														|  | 
 |  | +          // 表单参数
 | 
											
												
													
														|  | 
 |  | +          form: {},
 | 
											
												
													
														|  | 
 |  | +          // 表单校验
 | 
											
												
													
														|  | 
 |  | +          checkList: [],
 | 
											
												
													
														|  | 
 |  | +          roleOptions: [],
 | 
											
												
													
														|  | 
 |  | +          defaultKeys: [],
 | 
											
												
													
														|  | 
 |  | +          //是否关联下级
 | 
											
												
													
														|  | 
 |  | +          checked: false,
 | 
											
												
													
														|  | 
 |  | +          defaultProps: {
 | 
											
												
													
														|  | 
 |  | +            children: "children",
 | 
											
												
													
														|  | 
 |  | +            label: "name"
 | 
											
												
													
														|  | 
 |  | +          },
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +          rules: {
 | 
											
												
													
														|  | 
 |  | +            areaId: [
 | 
											
												
													
														|  | 
 |  | +              {required: true, message: '请选择区域', trigger: 'blur'},
 | 
											
												
													
														|  | 
 |  | +            ],
 | 
											
												
													
														|  | 
 |  | +            orgType: [
 | 
											
												
													
														|  | 
 |  | +              {required: true, message: '请选择机构类型', trigger: 'blur'},
 | 
											
												
													
														|  | 
 |  | +            ],
 | 
											
												
													
														|  | 
 |  | +            checkName: [
 | 
											
												
													
														|  | 
 |  | +              {required: true, message: '请输入NFC点位名称', trigger: 'change'}
 | 
											
												
													
														|  | 
 |  | +            ],
 | 
											
												
													
														|  | 
 |  | +          },
 | 
											
												
													
														|  | 
 |  | +          defaultKeys: []
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +        };
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +      created() {
 | 
											
												
													
														|  | 
 |  | +        this.getDeptTree();
 | 
											
												
													
														|  | 
 |  | +      this. getList();
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +      watch: {
 | 
											
												
													
														|  | 
 |  | +        // 根据名称筛选部门树
 | 
											
												
													
														|  | 
 |  | +        deptName(val) {
 | 
											
												
													
														|  | 
 |  | +          this.$refs.tree.filter(val);
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +      methods: {
 | 
											
												
													
														|  | 
 |  | +  /** 查询机构树数据 */
 | 
											
												
													
														|  | 
 |  | +  getDeptTree() {
 | 
											
												
													
														|  | 
 |  | +      deptTreeSelect().then((response) => {
 | 
											
												
													
														|  | 
 |  | +        this.deptOptions = response.data;
 | 
											
												
													
														|  | 
 |  | +      });
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +        /** treeSelect组件自定义数据*/
 | 
											
												
													
														|  | 
 |  | +        tenantIdnormalizer(node, instanceId) {
 | 
											
												
													
														|  | 
 |  | +      if (node.children && !node.children.length) {
 | 
											
												
													
														|  | 
 |  | +        delete node.children;
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +      return {
 | 
											
												
													
														|  | 
 |  | +        id: node.id,
 | 
											
												
													
														|  | 
 |  | +        label: node.shortName,
 | 
											
												
													
														|  | 
 |  | +        children: node.children,
 | 
											
												
													
														|  | 
 |  | +      };
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +        getPageIndex($index) {
 | 
											
												
													
														|  | 
 |  | +          //表格序号
 | 
											
												
													
														|  | 
 |  | +          return (
 | 
											
												
													
														|  | 
 |  | +            (this.queryParams.pageNum - 1) * this.queryParams.pageSize + $index + 1
 | 
											
												
													
														|  | 
 |  | +          );
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        handleExport() {
 | 
											
												
													
														|  | 
 |  | +      this.download('core/safetyInspectReport/export', {
 | 
											
												
													
														|  | 
 |  | +        ...this.queryParams
 | 
											
												
													
														|  | 
 |  | +      }, `${'【'+this.orgName+'】'+'-检查统计报表-'+this.formatTime(new Date(),'YYYYMMDD')}.xlsx`)
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +    
 | 
											
												
													
														|  | 
 |  | +     
 | 
											
												
													
														|  | 
 |  | +        getList() {
 | 
											
												
													
														|  | 
 |  | +          this.loading = true;
 | 
											
												
													
														|  | 
 |  | +          listIntrusionTestReport(this.queryParams).then(response => {
 | 
											
												
													
														|  | 
 |  | +            this.checkList = response.data;
 | 
											
												
													
														|  | 
 |  | +            this.title=response.title;
 | 
											
												
													
														|  | 
 |  | +            // this.total = response.data.total;
 | 
											
												
													
														|  | 
 |  | +            this.loading = false;
 | 
											
												
													
														|  | 
 |  | +          });
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        getAllOrg() {
 | 
											
												
													
														|  | 
 |  | +          selectAllOrg().then(response => {
 | 
											
												
													
														|  | 
 |  | +        this.orgOptions = response.data;
 | 
											
												
													
														|  | 
 |  | +      })
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | + 
 | 
											
												
													
														|  | 
 |  | +    
 | 
											
												
													
														|  | 
 |  | +        // 取消按钮
 | 
											
												
													
														|  | 
 |  | +        cancel() {
 | 
											
												
													
														|  | 
 |  | +          this.open = false;
 | 
											
												
													
														|  | 
 |  | +          this.reset();
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        // 表单重置
 | 
											
												
													
														|  | 
 |  | +        reset() {
 | 
											
												
													
														|  | 
 |  | +          this.form = {
 | 
											
												
													
														|  | 
 |  | +            id: null,
 | 
											
												
													
														|  | 
 |  | +            checkName: null,
 | 
											
												
													
														|  | 
 |  | +            areaId: null,
 | 
											
												
													
														|  | 
 |  | +            orgId: null,
 | 
											
												
													
														|  | 
 |  | +            createTime: null,
 | 
											
												
													
														|  | 
 |  | +            updateTime: null,
 | 
											
												
													
														|  | 
 |  | +            updateId: null,
 | 
											
												
													
														|  | 
 |  | +            createBy: null,
 | 
											
												
													
														|  | 
 |  | +            delFlag: null,
 | 
											
												
													
														|  | 
 |  | +            updateBy: null
 | 
											
												
													
														|  | 
 |  | +          };
 | 
											
												
													
														|  | 
 |  | +          this.resetForm("form");
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        /** 搜索按钮操作 */
 | 
											
												
													
														|  | 
 |  | +        handleQuery() {
 | 
											
												
													
														|  | 
 |  | +          this.queryParams.pageNum = 1;
 | 
											
												
													
														|  | 
 |  | +          this.getList();
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        /** 重置按钮操作 */
 | 
											
												
													
														|  | 
 |  | +        resetQuery() {
 | 
											
												
													
														|  | 
 |  | +          this.resetForm("queryForm");
 | 
											
												
													
														|  | 
 |  | +          this.handleQuery();
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +        // 多选框选中数据
 | 
											
												
													
														|  | 
 |  | +        handleSelectionChange(selection) {
 | 
											
												
													
														|  | 
 |  | +          this.ids = selection.map(item => item.id)
 | 
											
												
													
														|  | 
 |  | +          this.names = selection.map(item => item.checkName)
 | 
											
												
													
														|  | 
 |  | +          this.single = selection.length !== 1
 | 
											
												
													
														|  | 
 |  | +          this.multiple = !selection.length
 | 
											
												
													
														|  | 
 |  | +        },
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +    };
 | 
											
												
													
														|  | 
 |  | +  </script>
 | 
											
												
													
														|  | 
 |  | +  <style lang="scss" scoped>
 | 
											
												
													
														|  | 
 |  | +  ::v-deep.formTreeItem {
 | 
											
												
													
														|  | 
 |  | +    .el-form-item__content {
 | 
											
												
													
														|  | 
 |  | +      width: 264px;
 | 
											
												
													
														|  | 
 |  | +    }
 | 
											
												
													
														|  | 
 |  | +  }
 | 
											
												
													
														|  | 
 |  | +  </style>
 |