ソースを参照

Merge remote-tracking branch 'remotes/origin/VERSIONS-yinHuanQingDan' into leb-web-dev

dedsudiyu 1 日 前
コミット
e0873cdb7b

+ 72 - 0
src/api/safetyCheck/index.js

@@ -286,6 +286,7 @@ export function securityCheckSetOptionFinishCheck(query) {
 }
 //检查项-清除
 export function securityCheckSetOptionClearOptionData(query) {
+  console.log('query',query)
   return request({
     url: '/security/checkSetOption/clearOptionData',
     method: 'get',
@@ -943,3 +944,74 @@ export function securityMemberPlanMemberList(data) {
     data: data
   })
 }
+
+//隐患清单-左侧目录列表
+export function securityCheckHiddenDangerTitleList(data) {
+  return request({
+    url: '/security/checkHiddenDanger/titleList',
+    method: 'post',
+    data: data
+  })
+}
+
+//隐患清单-右侧数据列表
+export function securityCheckHiddenDangerList(data) {
+  return request({
+    url: '/security/checkHiddenDanger/list',
+    method: 'post',
+    data: data
+  })
+}
+
+//根据计划-查询相关学院列表
+export function securityMemberGetCollegeList (query) {
+  return request({
+    url: '/security/member/getCollegeList',
+    method: 'get',
+    params: query
+  })
+}
+
+//根据计划-查询当前用户权限范围(督导组/校级管理员)
+export function securityCheckHiddenDangerFindCurrentMemberRole (query) {
+  return request({
+    url: '/security/checkHiddenDanger/findCurrentMemberRole',
+    method: 'get',
+    params: query
+  })
+}
+
+//隐患清单-详情
+export function securityCheckHiddenDangerFindCheckHiddenDanger (query) {
+  return request({
+    url: '/security/checkHiddenDanger/findCheckHiddenDanger',
+    method: 'get',
+    params: query
+  })
+}
+
+//隐患清单-提交
+export function securityCheckHiddenDangerUpdate (data) {
+  return request({
+    url: '/security/checkHiddenDanger/update',
+    method: 'post',
+    data: data
+  })
+}
+
+//隐患清单-批量提交
+export function securityCheckHiddenDangerBatchHiddenDangerSubmit (data) {
+  return request({
+    url: '/security/checkHiddenDanger/batchHiddenDangerSubmit',
+    method: 'post',
+    data: data
+  })
+}
+//隐患清单-批量提交
+export function securityCheckPlanSubPlanCollegeList (data) {
+  return request({
+    url: '/security/checkPlan/subPlanCollegeList',
+    method: 'post',
+    data: data
+  })
+}

BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_bj@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_gd@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_jz@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_qd@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_sc@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_sctp@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_wc@1x.png


BIN
src/assets/ZDimages/safetyCheck/icon_yhqd_yqr@1x.png


+ 5 - 0
src/router/index.js

@@ -63,6 +63,11 @@ export const constantRoutes = [
     component: (resolve) => require(['@/views/basicsModules/homeXiNong.vue'], resolve),
     hidden: true
   },
+  {
+    path: '/schoolHiddenDangerAdd',
+    component: (resolve) => require(['@/views/safetyCheck/schoolInspect/schoolHiddenDangerList/addPage.vue'], resolve),
+    hidden: true
+  },
   {
     path: '',
     component: Layout,

+ 3 - 0
src/views/safetyCheck/components/inspectionItemsStatistics.vue

@@ -99,6 +99,7 @@
                         @sort-change="sortChange">
                 <el-table-column type="selection" width="50" :reserve-selection="true" align="center"/>
                 <el-table-column label="序号" type="index" width="60"/>
+                <el-table-column label="条款号" prop="oneLevelCode" width="100" show-overflow-tooltip/>
                 <el-table-column label="一级检查项" prop="oneLevelName" show-overflow-tooltip/>
                 <el-table-column label="隐患数" sortable="custom" prop="hazardNum" width="160" show-overflow-tooltip/>
                 <el-table-column label="占比" prop="ratio" width="160" show-overflow-tooltip>
@@ -123,6 +124,7 @@
                         @sort-change="sortChange">
                 <el-table-column type="selection" width="50" :reserve-selection="true" align="center"/>
                 <el-table-column label="序号" type="index" width="60"/>
+                <el-table-column label="条款号" prop="twoLevelCode" width="100" show-overflow-tooltip/>
                 <el-table-column label="二级检查项" prop="twoLevelName" show-overflow-tooltip/>
                 <el-table-column label="隐患数" sortable="custom" prop="hazardNum" width="160" show-overflow-tooltip/>
                 <el-table-column label="占比" prop="ratio" width="160" show-overflow-tooltip/>
@@ -141,6 +143,7 @@
                         @sort-change="sortChange">
                 <el-table-column type="selection" width="50" :reserve-selection="true" align="center"/>
                 <el-table-column label="序号" type="index" width="60"/>
+                <el-table-column label="条款号" prop="threeLevelCode" width="100" show-overflow-tooltip/>
                 <el-table-column label="三级检查项" prop="threeLevelName" show-overflow-tooltip/>
                 <el-table-column label="隐患数" sortable="custom" prop="hazardNum" width="160" show-overflow-tooltip/>
                 <el-table-column label="占比" prop="ratio" width="160" show-overflow-tooltip/>

+ 1 - 1
src/views/safetyCheck/components/projectAddPage.vue

@@ -54,7 +54,7 @@
               <el-form-item label="检查范围" prop="checkRange">
                 <el-radio-group v-model="dialogForm.checkRange" @change="checkRangeChange" :disabled="lookInfoType" style="min-width:90px;">
                   <el-radio :label="1" v-if="schoolCollegeType == 'school'">全校</el-radio>
-                  <el-radio :label="3" style="margin-right:40px;">实验室</el-radio>
+                  <!--<el-radio :label="3" style="margin-right:40px;">实验室</el-radio>-->
                 </el-radio-group>
               </el-form-item>
               <div class="sub-button-box"

+ 512 - 0
src/views/safetyCheck/components/schoolCheckItem.vue

@@ -0,0 +1,512 @@
+<!--检查项--->
+<template>
+  <div class="page-container checkItem">
+    <div class="page-container checkItem" v-if="pageType == 1">
+      <div class="page-top-title-box">
+        <p class="page-top-title-name-p">{{propsData.subName}}</p>
+        <p class="page-top-title-out-p" @click="backPage">返回</p>
+      </div>
+      <div class="content-box scrollbar-box">
+        <div class="page-form-title-box" style="border:none;">
+          <el-form :model="queryParams" class="form-box" ref="queryForm"
+                   :inline="true" style="width:100%;">
+            <!--<div class="table-school-college-toggle-box" v-if="propsData.manageStatus != 2">-->
+              <!--<p :class="checkStatus==null?'p-check':''" @click="tableCheck(null)">全部</p>-->
+              <!--<p :class="checkStatus==0?'p-check':''" @click="tableCheck(0)">待检查</p>-->
+              <!--&lt;!&ndash;<p :class="checkStatus==2?'p-check':''" @click="tableCheck(2)">检查中</p>&ndash;&gt;-->
+              <!--<p :class="checkStatus==1?'p-check':''" @click="tableCheck(1)">已检查</p>-->
+            <!--</div>-->
+            <el-form-item label="" prop="hazardCheckPro">
+              <el-cascader
+                placeholder="请选择检查项目"
+                style="width:200px;"
+                v-model="queryParams.hazardCheckPro"
+                filterable
+                :show-all-levels="false"
+                :options="cascaderData"
+                :props="{ value: 'id', label: 'labelName',emitPath:false }"
+              ></el-cascader>
+            </el-form-item>
+            <!--<el-form-item label="" prop="checkFlagInt" v-if="checkFlagIntType">-->
+            <!--<el-select v-model="queryParams.checkFlagInt" placeholder="检查结果" style="width: 200px">-->
+            <!--<el-option-->
+            <!--v-for="dict in optionList"-->
+            <!--:key="dict.value"-->
+            <!--:label="dict.label"-->
+            <!--:value="dict.value"-->
+            <!--/>-->
+            <!--</el-select>-->
+            <!--</el-form-item>-->
+            <el-form-item label="" prop="checkUserName">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.checkUserName"
+                placeholder="检查人"
+                style="width: 200px"
+              />
+            </el-form-item>
+            <el-form-item label="" prop="state">
+              <el-date-picker
+                :clearable="false"
+                v-model="dateRange"
+                size="small"
+                style="width: 240px"
+                value-format="yyyy-MM-dd"
+                type="daterange"
+                range-separator="-"
+                start-placeholder="开始日期"
+                end-placeholder="结束日期"
+              ></el-date-picker>
+            </el-form-item>
+            <p class="page-inquire-common-style-button" @click="handleQuery">查询</p>
+            <p class="page-reset-common-style-button" @click="resetQuery">重置</p>
+            <p class="page-save-common-style-button" style="float: right;"
+               v-if="propsData.manageStatus != 2"
+               v-hasPermiRouter="['security:checkPlan:detail']" @click="demo">新增隐患</p>
+          </el-form>
+        </div>
+        <div class="page-content-box" style="padding-top:0;">
+          <el-table class="table-box" border :data="dataList">
+            <el-table-column label="序号" type="index" width="60"/>
+            <el-table-column label="检查项目" prop="name" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{scope.row.hazardCheckCode}} {{scope.row.hazardCheckName}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="隐患描述" prop="hazardDescribe" width="400" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span v-if="scope.row.checkStatus == 0&&scope.row.checkDraftVo">{{scope.row.checkDraftVo.hazardDescribe}}</span>
+                <span v-else>{{scope.row.hazardDescribe}}</span>
+              </template>
+            </el-table-column>
+            <!--<el-table-column label="检查结果" prop="checkFlag" width="150" show-overflow-tooltip>-->
+            <!--<template slot-scope="scope">-->
+            <!--<span>{{scope.row.checkStatus!=1?'-':(scope.row.checkFlag?'符合':'不符合')}}</span>-->
+            <!--</template>-->
+            <!--</el-table-column>-->
+            <el-table-column label="检查人" prop="checkUserName" width="150" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{scope.row.checkStatus == 1?scope.row.checkUserName:'-'}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="检查时间" prop="createTime" width="180" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{ scope.row.checkStatus == 1?parseTime(scope.row.checkTime,'{y}-{m}-{d} {h}:{i}'):'-' }}</span>
+              </template>
+            </el-table-column>
+            <!--<el-table-column label="状态" prop="checkStatus" width="150" show-overflow-tooltip>-->
+              <!--<template slot-scope="scope">-->
+                <!--&lt;!&ndash;<span v-if="scope.row.checkStatus == 0&&scope.row.checkDraftVo">检查中</span>&ndash;&gt;-->
+                <!--&lt;!&ndash;<span v-else>{{scope.row.checkStatus == '0'?'未开始':(scope.row.checkStatus == '1'?'已完成':'')}}</span>&ndash;&gt;-->
+                <!--<span v-if="scope.row.checkStatus == 0&&scope.row.checkDraftVo">待检查</span>-->
+                <!--<span v-else>{{scope.row.checkStatus == '0'?'待检查':(scope.row.checkStatus == '1'?'已检查':'')}}</span>-->
+              <!--</template>-->
+            <!--</el-table-column>-->
+            <el-table-column label="操作" width="220" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <div class="table-button-box">
+                  <p class="table-button-null"></p>
+                  <!-- 校级 -->
+                  <!--<p class="table-button-p"-->
+                  <!--v-if="scope.row.checkStatus == 0 && propsData.pageType == 1"-->
+                  <!--@click="tableButton(1,scope.row)"-->
+                  <!--v-hasPermiRouter="['security:checkPlan:detail']"-->
+                  <!--&gt;开始检查</p>-->
+                  <!-- 院级 -->
+                  <!--<p class="table-button-p"-->
+                  <!--v-if="scope.row.checkStatus == 0 && propsData.pageType == 2"-->
+                  <!--@click="tableButton(1,scope.row)"-->
+                  <!--v-hasPermiRouter="['security:checkPlan_1:detail']"-->
+                  <!--&gt;开始检查</p>-->
+                  <!-- 校级 -->
+                  <p class="table-button-p"
+                     v-if="(scope.row.checkStatus == 1 && propsData.manageStatus != 2) && propsData.pageType == 1 &&scope.row.checkUserId == userId"
+                     @click="tableButton(3,scope.row)"
+                     v-hasPermiRouter="['security:checkPlan:detail']"
+                  >编辑</p>
+                  <!-- 院级 -->
+                  <p class="table-button-p"
+                     v-if="(scope.row.checkStatus == 1 && propsData.manageStatus != 2) && propsData.pageType == 2 && scope.row.checkUserId == userId"
+                     @click="tableButton(3,scope.row)"
+                     v-hasPermiRouter="['security:checkPlan_1:detail']"
+                  >编辑</p>
+                  <p class="table-button-p"
+                     v-if="scope.row.checkStatus == 1"
+                     @click="tableButton(2,scope.row)"
+                  >详情</p>
+                  <p class="table-button-p"
+                     v-if="scope.row.checkStatus == 1 && propsData.manageStatus != 2 && scope.row.checkUserId == userId"
+                     @click="tableButton(7,scope.row)"
+                  >清除</p>
+                  <p class="table-button-null"></p>
+                </div>
+              </template>
+            </el-table-column>
+          </el-table>
+          <pagination :page-sizes="[20, 30, 40, 50]"
+                      v-show="total>0"
+                      :total="total"
+                      :page.sync="queryParams.page"
+                      :limit.sync="queryParams.pageSize"
+                      @pagination="securityCheckPlanSetFindProgress"
+          />
+        </div>
+      </div>
+    </div>
+    <initiateInspect v-if="pageType == 2" :initiateInspectData="initiateInspectData"></initiateInspect>
+  </div>
+</template>
+
+<script>
+  //import { getDicts } from "@/api/commonality/noPermission";
+  //import { systemUserSelect } from "@/api/commonality/permission";
+  import {
+    securityCheckOptionList,
+    securityCheckSetOptionList,
+    securityCheckPlanSetFindProgress,
+    securityCheckSetOptionClearOptionData
+  } from '@/api/safetyCheck/index'
+  import initiateInspect from '@/views/safetyCheck/components/initiateInspect/initiateInspect.vue'
+
+  export default {
+    name: 'checkItem',
+    components: {
+      initiateInspect
+    },
+    props: {
+      propsData: {}
+    },
+    data() {
+      return {
+        userId:localStorage.getItem('userId'),
+        //页面状态
+        pageType: 1,
+        //状态选项卡
+        checkStatus: null,
+        checkFlagIntType: true,
+        //下拉列表数据
+        optionList: [
+          { value: 1, label: '符合' },
+          { value: 0, label: '不符合' },
+          // { value: 2, label: '草稿' }
+        ],
+        cascaderData: [],
+        //查询条件
+        queryParams: {
+          page: 1,
+          pageSize: 20,
+          hazardCheckPro: null,
+          // checkFlagInt: null,
+          checkUserName: ''
+        },
+        //时间数据
+        dateRange: [],
+        //列表数据
+        dataList: [],
+        //数据数量
+        total: 0,
+        //批次是否完成
+        checkSetType: false,
+        //组件传参
+        initiateInspectData: {}
+      }
+    },
+    created() {
+      this.securityCheckOptionList()
+      this.securityCheckPlanSetFindProgress()
+    },
+    mounted() {
+
+    },
+    methods: {
+      //开展检查
+      demo(){
+        let obj = JSON.parse(JSON.stringify(this.propsData))
+        obj.freeChoiceType = true;
+        obj.showType = false;
+        obj.orderTitle = '开始检查';
+        obj.orderType = '1';
+        this.$set(this,'initiateInspectData',obj);
+        this.$set(this, 'pageType', 2)
+      },
+      //选项卡切换
+      tableCheck(type) {
+        if (this.checkStatus !== type) {
+          if (type == null) {
+            //全部
+            this.$set(this, 'optionList',[{ value: 1, label: '符合' },{ value: 0, label: '不符合' },{ value: 2, label: '草稿' }])
+            this.$set(this, 'checkFlagIntType',true)
+          } else if (type == 0) {
+            //待检查
+            this.$set(this, 'checkFlagIntType',false)
+          } else if (type == 2) {
+            //草稿
+            this.$set(this, 'checkFlagIntType',false)
+          } else if (type == 1) {
+            //已检查
+            this.$set(this, 'optionList', [{ value: 1, label: '符合' },{ value: 0, label: '不符合' }])
+            this.$set(this, 'checkFlagIntType',true)
+          }
+          this.$set(this, 'checkStatus', type)
+          this.resetQuery()
+        }
+      },
+      // 返回按钮
+      backPage() {
+        this.$parent.tableButton(6)
+      },
+      //查询按钮
+      handleQuery() {
+        this.$set(this.queryParams, 'page', 1)
+        this.securityCheckPlanSetFindProgress()
+      },
+      //重置按钮
+      resetQuery() {
+        this.$set(this, 'dateRange', [])
+        this.$set(this, 'queryParams', {
+          page: 1,
+          pageSize: 20,
+          hazardCheckPro: null,
+          // checkFlagInt: null,
+          checkUserName: ''
+        })
+        this.securityCheckPlanSetFindProgress()
+      },
+      //获取数据列表
+      getList() {
+        let obj = JSON.parse(JSON.stringify(this.queryParams))
+        if (this.dateRange[0]) {
+          obj.startTime = this.dateRange[0] + 'T00:00:00'
+          obj.endTime = this.dateRange[1] + 'T23:59:59'
+        } else {
+          obj.startTime = ''
+          obj.endTime = ''
+        }
+        obj.manageId = this.propsData.manageId
+        obj.checkStatus = 1
+        obj.checkFlagInt = 0
+        // if(this.propsData.manageStatus == 2){
+        //   obj.checkStatus = 1
+        // }else{
+        //   obj.checkStatus = this.checkStatus
+        // }
+        securityCheckSetOptionList(obj).then(response => {
+          this.$set(this, 'dataList', response.data.records)
+          this.$set(this, 'total', response.data.total)
+        })
+      },
+      //查询检查批次是否完成
+      securityCheckPlanSetFindProgress() {
+        securityCheckPlanSetFindProgress({ planSetId: this.propsData.planSetId }).then(response => {
+          this.$set(this, 'checkSetType', response.data)
+          this.getList()
+        })
+      },
+      //检查项列表
+      securityCheckOptionList() {
+        securityCheckOptionList({}).then(response => {
+          let list = this.getCascaderData(response.data)
+          this.$set(this, 'cascaderData', list)
+        })
+      },
+      getCascaderData(list) {
+        let self = this
+        for (let i = 0; i < list.length; i++) {
+          list[i].labelName = list[i].code ? list[i].code + ' ' + list[i].name : list[i].name
+          if (list[i].children) {
+            if (list[i].children[0]) {
+              list[i].children = self.getCascaderData(list[i].children)
+            } else {
+              if (list[i].level != 3) {
+                list.splice(i, 1)
+                i--
+              } else {
+                delete list[i].children
+              }
+            }
+          } else {
+            if (list[i].level != 3) {
+              list.splice(i, 1)
+              i--
+            } else {
+              delete list[i].children
+            }
+          }
+        }
+        for (let i = 0; i < list.length; i++) {
+          list[i].labelName = list[i].code ? list[i].code + ' ' + list[i].name : list[i].name
+          if (list[i].children) {
+            if (list[i].children[0]) {
+              list[i].children = self.getCascaderData(list[i].children)
+            } else {
+              if (list[i].level != 3) {
+                list.splice(i, 1)
+                i--
+              } else {
+                delete list[i].children
+              }
+            }
+          } else {
+            if (list[i].level != 3) {
+              list.splice(i, 1)
+              i--
+            } else {
+              delete list[i].children
+            }
+          }
+        }
+        for (let i = 0; i < list.length; i++) {
+          list[i].labelName = list[i].code ? list[i].code + ' ' + list[i].name : list[i].name
+          if (list[i].children) {
+            if (list[i].children[0]) {
+              list[i].children = self.getCascaderData(list[i].children)
+            } else {
+              if (list[i].level != 3) {
+                list.splice(i, 1)
+                i--
+              } else {
+                delete list[i].children
+              }
+            }
+          } else {
+            if (list[i].level != 3) {
+              list.splice(i, 1)
+              i--
+            } else {
+              delete list[i].children
+            }
+          }
+        }
+        return list
+      },
+      //操作按钮
+      tableButton(type, row) {
+        let self = this
+        if (type == 1) {
+          //开始检查
+          this.$set(this, 'pageType', 2)
+          let obj = JSON.parse(JSON.stringify(row))
+          obj.manageId = this.propsData.manageId
+          obj.showType = false
+          obj.orderTitle = '开始检查'
+          obj.orderType = '1'
+          this.$set(this, 'initiateInspectData', obj)
+        } else if (type == 2) {
+          //详情
+          this.$set(this, 'pageType', 2)
+          let obj = JSON.parse(JSON.stringify(row))
+          obj.manageId = this.propsData.manageId
+          obj.showType = true
+          obj.orderTitle = '检查详情'
+          obj.orderType = '2'
+          this.$set(this, 'initiateInspectData', obj)
+        } else if (type == 3) {
+          //编辑
+          this.$set(this, 'pageType', 2)
+          let obj = JSON.parse(JSON.stringify(row))
+          obj.manageId = this.propsData.manageId
+          obj.showType = false
+          obj.orderType = '1'
+          this.$set(this, 'initiateInspectData', obj)
+        } else if (type == 6) {
+          //返回并刷新
+          this.$set(this, 'pageType', 1)
+          this.securityCheckPlanSetFindProgress()
+        } else if (type == 7) {
+          //清除提交记录
+          this.$confirm('确认清除该隐患信息?', "警告", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }).then(function() {
+          }).then(() => {
+            securityCheckSetOptionClearOptionData({setOptionId:row.setOptionId}).then(response => {
+              self.msgSuccess(response.message)
+              self.getList();
+            });
+          }).catch(() => {});
+        }
+      }
+    }
+  }
+</script>
+
+<style scoped lang="scss">
+  .checkItem {
+    .content-box {
+      flex: 1;
+      display: flex;
+      flex-direction: column;
+      overflow: hidden;
+      .table-school-college-toggle-box {
+        overflow: hidden;
+        display: inline-block;
+        margin-right: 10px;
+        p {
+          display: inline-block;
+          text-align: center;
+          width: 80px;
+          line-height: 40px;
+          height: 40px;
+          color: #333;
+          background-color: #fff;
+          border: 1px solid #E0E0E0;
+          font-size: 14px;
+          cursor: pointer;
+        }
+        p:nth-child(1) {
+          border-top-left-radius: 4px;
+          border-bottom-left-radius: 4px;
+          /*border-right:none;*/
+        }
+        p:nth-child(3) {
+          border-top-right-radius: 4px;
+          border-bottom-right-radius: 4px;
+          /*border-left:none;*/
+        }
+        .p-check {
+          border: 1px solid #0183FA;
+          background-color: #0183FA;
+          color: #fff;
+        }
+      }
+      .form-button-max-big-box-me {
+        display: inline-block;
+        overflow: hidden;
+        margin-right: 10px;
+        .form-button-big-box-me {
+          display: flex;
+          div {
+            position: relative;
+            height: 40px;
+            width: 100px;
+            line-height: 40px;
+            text-align: center;
+            color: #999;
+            font-size: 14px;
+            border: 1px solid #999;
+            border-radius: 4px;
+            font-weight: 500;
+            cursor: pointer;
+            .icon-p-me {
+              width: 15px;
+              height: 15px;
+              line-height: 15px;
+              text-align: center;
+              position: absolute;
+              right: 0;
+              bottom: 0;
+              color: #fff;
+              background: #0183fa;
+              border-top-left-radius: 4px;
+            }
+          }
+          .checkDiv-me {
+            color: #0183FA !important;
+            border: 1px solid #0183FA !important;
+          }
+        }
+      }
+    }
+  }
+</style>

+ 420 - 0
src/views/safetyCheck/components/schoolInspectStatistics.vue

@@ -0,0 +1,420 @@
+<!--检查明细--->
+<template>
+  <div class="page-container checkItem">
+    <div class="page-container checkItem" v-if="pageType == 1">
+      <div class="page-top-title-box">
+        <p class="page-top-title-name-p">{{propsData.title}}</p>
+        <p class="page-top-title-out-p" @click="backPage">返回</p>
+      </div>
+      <div class="content-box scrollbar-box">
+        <div class="page-form-title-box" style="border:none;">
+          <el-form :model="queryParams" class="form-box" ref="queryForm"
+                   :inline="true" style="width:100%;">
+            <!--<div class="table-school-college-toggle-box" v-if="!propsData.deptId&&!propsData.subId&&propsData.planStatus!=2">-->
+              <!--<p :class="checkStatus==null?'p-check':''" @click="tableCheck(null)">全部</p>-->
+              <!--<p :class="checkStatus==0?'p-check':''" @click="tableCheck(0)">待检查</p>-->
+              <!--<p :class="checkStatus==1?'p-check':''" @click="tableCheck(1)">已检查</p>-->
+            <!--</div>-->
+            <el-form-item label="" prop="hazardCheckName">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.hazardCheckName"
+                placeholder="模糊搜索检查项"
+                style="width: 140px"
+              />
+            </el-form-item>
+            <el-form-item label="" prop="deptId" v-if="!propsData.deptId&&!propsData.subId">
+              <el-select v-model="queryParams.deptId" placeholder="学院单位" style="width: 120px">
+                <el-option
+                  v-for="dict in deptOption"
+                  :key="dict.deptId"
+                  :label="dict.deptName"
+                  :value="dict.deptId"
+                />
+              </el-select>
+            </el-form-item>
+            <el-form-item label="" prop="subName">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.subName"
+                placeholder="实验室/房间号"
+                style="width: 120px"
+              />
+            </el-form-item>
+            <el-form-item label="" prop="checkUserName">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.checkUserName"
+                placeholder="检查人/整改人"
+                style="width: 120px"
+              />
+            </el-form-item>
+            <el-form-item label="" prop="checkName">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.checkName"
+                placeholder="检查名称"
+                style="width: 150px"
+              />
+            </el-form-item>
+            <!--<el-form-item label="" prop="checkFlag">-->
+              <!--<el-select v-model="queryParams.checkFlag" placeholder="检查结果" style="width: 120px">-->
+                <!--<el-option-->
+                  <!--v-for="dict in optionList"-->
+                  <!--:key="dict.value"-->
+                  <!--:label="dict.label"-->
+                  <!--:value="dict.value"-->
+                <!--/>-->
+              <!--</el-select>-->
+            <!--</el-form-item>-->
+            <p class="page-inquire-common-style-button" @click="handleQuery">查询</p>
+            <p class="page-reset-common-style-button" @click="resetQuery">重置</p>
+            <!--<el-form-item style="float: right;">-->
+              <!--<export-component :exportConfig="exportConfig"></export-component>-->
+            <!--</el-form-item>-->
+          </el-form>
+        </div>
+        <div class="page-content-box" style="padding-top:0;">
+          <el-table class="table-box" ref="table-box" v-loading="loading" border :data="dataList"
+                    @selection-change="handleSelectionChange" :row-key="getRowKeys" @sort-change="sortChange">
+            <el-table-column type="selection" width="50" :reserve-selection="true" align="center"/>
+            <el-table-column label="序号" type="index" width="60"/>
+            <el-table-column label="检查名称" prop="checkName"  width="200" show-overflow-tooltip/>
+            <el-table-column label="实验室" prop="subName"  width="200" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{scope.row.subName}}{{scope.row.roomNum?scope.row.roomNum:''}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="检查项" prop="content" width="280" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{scope.row.hazardCheckCode}}{{scope.row.hazardCheckName}}</span>
+              </template>
+            </el-table-column>
+            <!--<el-table-column label="检查状态" prop="checkStatus" width="100" show-overflow-tooltip>-->
+              <!--<template slot-scope="scope">-->
+                <!--<span>{{scope.row.checkStatus==0?'待检查':'已检查'}}</span>-->
+              <!--</template>-->
+            <!--</el-table-column>-->
+            <el-table-column label="检查人" prop="checkUserName" width="80" show-overflow-tooltip/>
+            <!--<el-table-column label="检查结果" prop="checkFlag" width="100" show-overflow-tooltip>-->
+              <!--<template slot-scope="scope">-->
+                <!--<span v-if="scope.row.checkStatus!=0">{{scope.row.checkFlag?'符合':'不符合'}}</span>-->
+              <!--</template>-->
+            <!--</el-table-column>-->
+            <el-table-column label="检查时间" sortable="custom" prop="checkTime" width="150" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{ parseTime(scope.row.checkTime,"{y}-{m}-{d} {h}:{i}") }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="整改状态" prop="rectifyStatus" width="100" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span v-if="scope.row.checkStatus!=0&&!scope.row.checkFlag">{{scope.row.rectifyStatus==1?'已完成':(scope.row.rectifyStatus==2?'待整改':(scope.row.rectifyStatus==4?'暂无法整改':''))}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="整改人" prop="rectifyName" width="90" show-overflow-tooltip/>
+            <el-table-column label="整改时间" sortable="custom" prop="rectifyTime" width="150" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{ parseTime(scope.row.rectifyTime,"{y}-{m}-{d} {h}:{i}") }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="复查状态" prop="reviewStatus" width="80" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span v-if="scope.row.checkStatus!=0&&!scope.row.checkFlag&&scope.row.rectifyStatus!=2">{{scope.row.reviewStatus==1?'已复查':(scope.row.reviewStatus==0?'待复查':'')}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="复查人" prop="reviewName" width="80" show-overflow-tooltip/>
+            <el-table-column label="复查结果" prop="examineResult" width="100" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{scope.row.examineResult==1?'复查完毕':(scope.row.examineResult==0?'退回整改':'')}}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="操作" width="100" show-overflow-tooltip >
+              <template slot-scope="scope">
+                <div class="table-button-box">
+                  <p class="table-button-null"></p>
+                  <p class="table-button-p"
+                     @click="tableButton(2,scope.row)"
+
+                  >详情</p>
+                  <p class="table-button-null"></p>
+                </div>
+              </template>
+            </el-table-column>
+          </el-table>
+          <pagination :page-sizes="[20, 30, 40, 50]"
+                      v-show="total>0"
+                      :total="total"
+                      :page.sync="queryParams.page"
+                      :limit.sync="queryParams.pageSize"
+                      @pagination="getList"
+          />
+        </div>
+      </div>
+    </div>
+    <initiateInspect v-if="pageType == 2" :initiateInspectData="initiateInspectData"></initiateInspect>
+  </div>
+</template>
+
+<script>
+  import {
+    getDeptDropList,
+  } from '@/api/commonality/permission'
+  import {
+    securityCheckDetailsCheckList
+  } from "@/api/safetyCheck/index";
+  import initiateInspect from "@/views/safetyCheck/components/initiateInspect/initiateInspect.vue";
+  import exportComponent from "@/views/safetyCheck/components/exportComponent/exportComponent.vue";
+  export default {
+    name: 'checkItem',
+    components: {
+      initiateInspect,
+      exportComponent,
+    },
+    props:{
+      propsData:{},
+    },
+    data(){
+      return{
+        //导出配置
+        exportConfig:{
+          api:'/security/checkDetails/export  ',             //导出接口地址
+          ids:'',                                       //勾选导出,勾选的IDS
+          fileName:'检查明细信息',                         //导出文件的命名
+          screenData:{},
+        },
+        //页面状态
+        pageType:1,
+        //状态选项卡
+        checkStatus:null,
+        //页面遮罩
+        loading:false,
+        //下拉列表数据
+        deptOption:[],
+        optionList:[{value:1,label:'符合'},{value:0,label:'不符合'}],
+        //查询条件
+        queryParams:{
+          page:1,
+          pageSize:20,
+          hazardCheckName:"",
+          deptId :null,
+          subName :"",
+          checkUserName :"",
+          checkName :"",
+          checkFlag :null,
+          columnName :"",
+          sort :"",
+        },
+        //列表数据
+        dataList:[],
+        //数据数量
+        total:0,
+        //子组件数据
+        initiateInspectData:{},
+      }
+    },
+    created(){
+      if(this.propsData.deptId||this.propsData.subId){
+        this.$set(this,'checkStatus',1);
+      }
+      this.getDeptDropList();
+    },
+    mounted(){
+      this.getList();
+    },
+    methods:{
+      //选项卡切换
+      tableCheck(type){
+        if (this.checkStatus !== type){
+          this.$set(this,'checkStatus',type);
+          this.resetQuery();
+        }
+      },
+      // 返回按钮
+      backPage(){
+        this.$parent.tableButton(6);
+      },
+      //查询按钮
+      handleQuery(){
+        this.$set(this.queryParams,'page',1);
+        this.getList();
+      },
+      //重置按钮
+      resetQuery(){
+        this.$refs['table-box'].clearSelection();
+        this.$set(this.exportConfig,'ids','');
+        this.$set(this,'queryParams',{
+          page:1,
+          pageSize:20,
+          hazardCheckName:"",
+          deptId :null,
+          subName :"",
+          checkUserName :"",
+          checkName :"",
+          checkFlag :null,
+          columnName :"",
+          sort :"",
+        });
+        this.getList();
+      },
+      getRowKeys(row) {
+        return row.setOptionId
+      },
+      // 多选框选中数据
+      handleSelectionChange(selection) {
+        this.$set(this.exportConfig,'ids',selection.map(item => item.setOptionId));
+      },
+      //时间排序方法
+      sortChange(val){
+        this.$set(this.queryParams,'columnName',val.prop);
+        this.$set(this.queryParams,'sort',val.order=='ascending'?'asc':(val.order=='descending'?'desc':''));
+        this.handleQuery();
+      },
+      //获取数据列表
+      getList(){
+        this.$set(this,'loading',true);
+        let obj = JSON.parse(JSON.stringify(this.queryParams))
+        if(this.propsData.planId){
+          obj.planId = this.propsData.planId
+          this.$set(this.exportConfig,'customKey','planId');
+          this.$set(this.exportConfig,'customValue',obj.planId);
+        }else if(this.propsData.deptId){
+          obj.deptId = this.propsData.deptId
+          obj.planId = this.propsData.deptPlanId
+          this.$set(this.exportConfig,'customKey','deptId');
+          this.$set(this.exportConfig,'customValue',obj.deptId);
+        }else if(this.propsData.subId){
+          obj.subId = this.propsData.subId
+          obj.planId = this.propsData.subPlanId
+          this.$set(this.exportConfig,'customKey','subId');
+          this.$set(this.exportConfig,'customValue',obj.subId);
+        }
+        if (this.propsData.planStatus == 2){
+          obj.checkStatus = 1;
+        } else{
+          obj.checkStatus = this.checkStatus;
+        }
+        obj.checkFlag = 0;
+        this.$set(this.exportConfig,'screenData',obj);
+        securityCheckDetailsCheckList(obj).then(response => {
+          this.$set(this,'loading',false);
+          this.$set(this,'dataList',response.data.records);
+          this.$set(this,'total',response.data.total);
+        });
+      },
+      //操作按钮
+      tableButton(type,row){
+        let self = this;
+        if(type == 2){
+          //详情
+          this.$set(this,'pageType',2);
+          let obj = JSON.parse(JSON.stringify(row))
+          obj.planId = this.propsData.planId;
+          obj.showType = true;
+          obj.orderTitle = '检查详情';
+          obj.orderType = '2';
+          this.$set(this,'initiateInspectData',obj);
+        }else if(type == 6){
+          //返回并刷新
+          this.$set(this,'pageType',1);
+          this.getList();
+        }
+      },
+      //学院列表
+      getDeptDropList() {
+        getDeptDropList({ deptName: '', level: 2, deptType: 1 }).then(response => {
+          this.$set(this, 'deptOption', response.data)
+        })
+      },
+    },
+  }
+</script>
+
+<style scoped lang="scss">
+  .checkItem{
+    .content-box{
+      flex:1;
+      display: flex;
+      flex-direction: column;
+      overflow: hidden;
+      .table-school-college-toggle-box{
+        overflow: hidden;
+        display: inline-block;
+        margin-right:10px;
+        p{
+          display: inline-block;
+          text-align: center;
+          width:80px;
+          line-height:40px;
+          height:40px;
+          color:#333;
+          background-color: #fff;
+          border:1px solid #E0E0E0;
+          font-size:14px;
+          cursor: pointer;
+        }
+        p:nth-child(1){
+          border-top-left-radius: 4px;
+          border-bottom-left-radius: 4px;
+          /*border-right:none;*/
+        }
+        p:nth-child(4){
+          border-top-right-radius: 4px;
+          border-bottom-right-radius: 4px;
+          /*border-left:none;*/
+        }
+        .p-check{
+          border:1px solid #0183FA;
+          background-color: #0183FA;
+          color:#fff;
+        }
+      }
+      .form-button-max-big-box-me{
+        display: inline-block;
+        overflow: hidden;
+        margin-right:10px;
+        .form-button-big-box-me{
+          display: flex;
+          div{
+            position: relative;
+            height:40px;
+            width:100px;
+            line-height: 40px;
+            text-align: center;
+            color:#999;
+            font-size:14px;
+            border:1px solid #999;
+            border-radius:4px;
+            font-weight:500;
+            cursor: pointer;
+            .icon-p-me{
+              width:15px;
+              height:15px;
+              line-height:15px;
+              text-align: center;
+              position: absolute;
+              right:0;
+              bottom:0;
+              color:#fff;
+              background: #0183fa;
+              border-top-left-radius:4px;
+            }
+          }
+          .checkDiv-me{
+            color:#0183FA!important;
+            border:1px solid #0183FA!important;
+          }
+        }
+      }
+    }
+  }
+  .num-data-box{
+    background: rgba(1,131,250,0.2);
+    color:#0183FA;
+    font-size:14px;
+    line-height:40px;
+    padding:0 20px;
+    border-radius:4px;
+    margin:0px 20px 20px 20px;
+    width: 330px;
+  }
+</style>

+ 48 - 32
src/views/safetyCheck/schoolInspect/inspectManage/index.vue

@@ -60,12 +60,12 @@
         <div class="page-form-title-box" style="border:none;" :class="advancedType?'page-advanced-form-title-box':''">
           <el-form :model="queryParams" class="form-box" ref="queryForm"
                    :inline="true" style="width:100%;">
-            <div class="table-school-college-toggle-box">
-              <p :class="tableButtonCheckType===''?'p-check':''" @click="tableCheck('')">全部</p>
-              <p :class="tableButtonCheckType===0?'p-check':''" @click="tableCheck(0)">未完成</p>
-              <!--<p :class="tableButtonCheckType===1?'p-check':''" @click="tableCheck(1)">检查中</p>-->
-              <p :class="tableButtonCheckType===2?'p-check':''" @click="tableCheck(2)">已完成</p>
-            </div>
+            <!--<div class="table-school-college-toggle-box">-->
+              <!--<p :class="tableButtonCheckType===''?'p-check':''" @click="tableCheck('')">全部</p>-->
+              <!--<p :class="tableButtonCheckType===0?'p-check':''" @click="tableCheck(0)">未完成</p>-->
+              <!--&lt;!&ndash;<p :class="tableButtonCheckType===1?'p-check':''" @click="tableCheck(1)">检查中</p>&ndash;&gt;-->
+              <!--<p :class="tableButtonCheckType===2?'p-check':''" @click="tableCheck(2)">已完成</p>-->
+            <!--</div>-->
             <el-form-item label="" prop="deptId">
               <el-select v-model="queryParams.deptId" placeholder="学院单位" style="width:157px;">
                 <el-option
@@ -76,7 +76,15 @@
                 />
               </el-select>
             </el-form-item>
-            <el-form-item label="" prop="floorId">
+            <el-form-item label="" prop="searchValue">
+              <el-input
+                maxLength="30"
+                v-model="queryParams.searchValue"
+                placeholder="实验室/房间号"
+                style="width:170px;"
+              />
+            </el-form-item>
+            <el-form-item label="" prop="floorId" v-if="advancedType">
               <!--<el-select v-model="queryParams.floorId" placeholder="楼栋" style="width:150px;">-->
                 <!--<el-option-->
                   <!--v-for="dict in buildOption"-->
@@ -115,22 +123,14 @@
                 />
               </el-select>
             </el-form-item>
-            <el-form-item label="" prop="searchValue" v-if="advancedType">
-              <el-input
-                maxLength="30"
-                v-model="queryParams.searchValue"
-                placeholder="实验室/房间号"
-                style="width:170px;"
-              />
-            </el-form-item>
             <p class="page-inquire-common-style-button" @click="handleQuery">查询</p>
             <p class="page-reset-common-style-button" @click="resetQuery">重置</p>
             <p class="page-save-common-style-button" style="display: inline-block;margin-left:10px;" @click="searchToggle">{{advancedType?'普通搜索':'高级搜索'}}</p>
-            <p class="page-save-common-style-button" style="display: inline-block;margin-left:10px;"
-               @click="tableButton(3)"
-               v-if="memberRole != 3"
-               v-hasPermiRouter="['security:checkSetOption:batch']"
-            >检查完成</p>
+            <!--<p class="page-save-common-style-button" style="display: inline-block;margin-left:10px;"-->
+               <!--@click="tableButton(3)"-->
+               <!--v-if="memberRole != 3"-->
+               <!--v-hasPermiRouter="['security:checkSetOption:batch']"-->
+            <!--&gt;检查完成</p>-->
           </el-form>
         </div>
         <div class="page-conten-box page-content-right-bottom-box">
@@ -161,12 +161,12 @@
                   <p class="table-button-p"
                      @click="tableButton(1,scope.row)"
                      v-hasPermiRouter="['security:checkSetOption:list']"
-                  >检查项</p>
+                  >隐患明细</p>
                   <p class="table-button-p"
                      v-if='scope.row.manageStatus !=2'
                      @click="tableButton(2,scope.row)"
                      v-hasPermiRouter="['security:checkPlan:detail']"
-                  >开展检查</p>
+                  >新增隐患</p>
                   <p class="table-button-null"></p>
                 </div>
               </template>
@@ -182,7 +182,7 @@
         </div>
       </div>
     </div>
-    <checkItem :propsData="propsData" v-if="pageType === 2"></checkItem>
+    <schoolCheckItem :propsData="propsData" v-if="pageType === 2"></schoolCheckItem>
     <initiateInspect v-if="pageType == 3" :initiateInspectData="initiateInspectData"></initiateInspect>
   </div>
 </template>
@@ -196,14 +196,16 @@
   import {
     securityCheckPlanTitleList,
     securityCheckManageList,
+    securityMemberGetCollegeList,
+    securityCheckPlanSubPlanCollegeList,
     securityCheckSetOptionFinishCheckBatch,
   } from '@/api/safetyCheck/index'
-  import checkItem from "@/views/safetyCheck/components/checkItem.vue";
+  import schoolCheckItem from "@/views/safetyCheck/components/schoolCheckItem.vue";
   import initiateInspect from "@/views/safetyCheck/components/initiateInspect/initiateInspect.vue";
   export default {
     name: 'index',
     components: {
-      checkItem,
+      schoolCheckItem,
       initiateInspect,
     },
     data () {
@@ -211,7 +213,7 @@
         //页面状态
         pageType:1,
         //复查状态选项卡
-        tableButtonCheckType:'',
+        tableButtonCheckType:0,
         //页面遮罩
         loading:false,
         //学院
@@ -268,7 +270,6 @@
     },
     mounted () {
       this.getTitleList();
-      this.getDeptDropList();
       this.systemBuildingGetOptList();
       this.laboratoryClassLevelGetList();
       this.laboratoryClassTypeGetList();
@@ -291,6 +292,11 @@
           this.$set(this,'checkSetProgress',this.leftListData[index].checkPlanSetVoList[0].checkSetProgress);
           this.$set(this,'memberRole',this.leftListData[index].memberRole);
           this.resetQuery();
+          if (this.leftListData[index].checkRange!=3){
+            this.securityMemberGetCollegeList();
+          } else {
+            this.securityCheckPlanSubPlanCollegeList();
+          }
         }
       },
       //左侧计划子级切换
@@ -343,6 +349,11 @@
           if(response.data.records[0]){
             this.$set(this,'checkSetProgress',this.leftListData[0].checkPlanSetVoList[0].checkSetProgress);
             this.$set(this,'memberRole',this.leftListData[0].memberRole);
+            if (this.leftListData[0].checkRange!=3){
+              this.securityMemberGetCollegeList();
+            } else {
+              this.securityCheckPlanSubPlanCollegeList();
+            }
           }
         });
       },
@@ -365,12 +376,12 @@
           planSetId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planSetId,
           page:this.queryParams.page,
           pageSize:this.queryParams.pageSize,
-          manageStatus:this.tableButtonCheckType,
+          // manageStatus:this.tableButtonCheckType,
           deptId:this.queryParams.deptId,
-          floorId:this.queryParams.floorId,
+          searchValue:this.queryParams.searchValue,
         }
         if(this.advancedType){
-          obj.searchValue = this.queryParams.searchValue;
+          obj.floorId = this.queryParams.floorId;
           obj.typeId = this.queryParams.typeId;
           obj.levelId = this.queryParams.levelId;
         }
@@ -428,8 +439,13 @@
       },
       /*********************************** 学院/楼栋/分类/分级 ***********************************/
       //学院下拉列表
-      getDeptDropList(){
-        getDeptDropList({level: 2, deptType: 1 }).then(response => {
+      securityMemberGetCollegeList(){
+        securityMemberGetCollegeList({planId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planId}).then(response => {
+          this.$set(this,'deptOption',response.data);
+        });
+      },
+      securityCheckPlanSubPlanCollegeList(){
+        securityCheckPlanSubPlanCollegeList({planId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planId}).then(response => {
           this.$set(this,'deptOption',response.data);
         });
       },

+ 6 - 6
src/views/safetyCheck/schoolInspect/inspectProject/index.vue

@@ -107,9 +107,9 @@
                    v-hasPermiRouter="['security:checkPlan:edit']"
                 >编辑</p>
                 <p class="table-button-p"
+                   v-if="scope.row.planStatus!=0"
                    @click="tableButton(5,scope.row)"
-
-                >检查明细</p>
+                >隐患明细</p>
                 <p class="table-button-p"
                    v-if="scope.row.planStatus==0&&adminIdentity=='school'"
                    @click="tableButton(4,scope.row)"
@@ -130,7 +130,7 @@
       </div>
     </div>
     <projectAddPage :propsData="propsData" v-if="pageType === 2"></projectAddPage>
-    <inspect-statistics :propsData="propsData" v-if="pageType === 5"></inspect-statistics>
+    <schoolInspectStatistics :propsData="propsData" v-if="pageType === 5"></schoolInspectStatistics>
   </div>
 </template>
 <script>
@@ -139,12 +139,12 @@
     securityCheckPlanDelete,
   } from '@/api/safetyCheck/index'
   import projectAddPage from "@/views/safetyCheck/components/projectAddPage.vue";
-  import inspectStatistics from "@/views/safetyCheck/components/inspectStatistics.vue";
+  import schoolInspectStatistics from "@/views/safetyCheck/components/schoolInspectStatistics.vue";
   export default {
     name: 'index',
     components: {
       projectAddPage,
-      inspectStatistics,
+      schoolInspectStatistics,
     },
     data () {
       return {
@@ -269,7 +269,7 @@
           this.$set(this,'propsData',{
             planId : row.planId,
             title:row.planTitle,
-            planStatus:row.planStatus
+            planStatus:row.planStatus,
           });
           this.$set(this,'pageType',5);
         }else if(type == 6){

ファイルの差分が大きいため隠しています
+ 1273 - 0
src/views/safetyCheck/schoolInspect/schoolHiddenDangerList/addPage.vue


+ 702 - 0
src/views/safetyCheck/schoolInspect/schoolHiddenDangerList/index.vue

@@ -0,0 +1,702 @@
+<!-- 校级隐患清单 -->
+<template>
+  <div class="app-container schoolHiddenDangerList">
+    <div class="page-container schoolHiddenDangerListPage" v-if="pageType === 1">
+      <!--左侧计划栏-->
+      <div class="page-content-left-box">
+        <!--计划栏搜索框-->
+        <div>
+          <el-form :model="leftQueryParams" class="form-box" ref="leftQueryForm"
+                   :inline="true" style="width:100%;">
+            <el-form-item label="" prop="time">
+              <el-date-picker
+                v-model="leftQueryParams.time"
+                type="year"
+                style="width: 100px"
+                value-format="yyyy"
+                placeholder="年">
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item label="" prop="searchValue">
+              <el-input
+                maxLength="30"
+                v-model="leftQueryParams.searchValue"
+                placeholder="输入检计划名称快速检索"
+                clearable
+                @clear="leftClear"
+                style="width: 265px"
+              />
+            </el-form-item>
+            <p class="page-save-common-style-button" style="width:80px;display: inline-block" @click="leftHandleQuery">查询</p>
+          </el-form>
+        </div>
+        <!--计划栏列表-->
+        <div class="left-max-list-box scrollbar-box">
+          <div class="left-list-for-max-big-box" v-for="(bigItem,bigIndex) in leftListData" :key="bigIndex">
+            <div class="left-list-title-box" @click="leftBigCheckButton(bigIndex)">
+              <p :class="bigIndex == leftBigCheckType?'el-icon-caret-bottom':'el-icon-caret-right'"></p>
+              <p>{{bigItem.planTitle}}</p>
+              <p>{{bigItem.checkTypeName}}</p>
+            </div>
+            <div class="left-list-box">
+              <div class="left-list-for-box" v-if="bigIndex == leftBigCheckType"
+                   @click="leftCheckButton(index,bigIndex)"
+                   :class="index == leftCheckType ? 'check-left-list-for-box':''"
+                   v-for="(item,index) in bigItem.checkPlanSetVoList" :key="index">
+                <div class="left-list-text-box">
+                  <p>{{item.checkName}}</p>
+                  <p>检查开始时间:{{parseTime(item.checkStartTime,"{y}-{m}-{d}")}}</p>
+                </div>
+                <div class="left-list-progress-box">
+                  <el-progress :stroke-width="14" :percentage="item.checkSetProgress"></el-progress>
+                </div>
+              </div>
+            </div>
+          </div>
+          <p v-if="!leftListData[0]" class="left-list-for-null-p">暂无数据</p>
+        </div>
+        <pagination :page-sizes="[20, 30, 40, 50]"
+                    v-show="titleTotal>0"
+                    :total="titleTotal"
+                    :page.sync="leftQueryParams.page"
+                    :limit.sync="leftQueryParams.pageSize"
+                    @pagination="getTitleList"
+        />
+      </div>
+      <div class="page-content-center-box"></div>
+      <!--右侧数据表格-->
+      <div class="page-content-right-box">
+        <div class="page-form-title-box" style="border:none;">
+          <el-form :model="queryParams" class="form-box" ref="queryForm"
+                   :inline="true" style="width:100%;">
+            <el-form-item label="" prop="deptId">
+              <el-select v-model="queryParams.deptId" placeholder="选择二级学院单位" style="width:180px;">
+                <el-option
+                  v-for="dict in deptOption"
+                  :key="dict.deptId"
+                  :label="dict.deptName"
+                  :value="dict.deptId"
+                />
+              </el-select>
+            </el-form-item>
+            <el-form-item label="" prop="leaderSubmitStatus" v-if="!isSchoolAdmin">
+              <el-select v-model="queryParams.leaderSubmitStatus" placeholder="状态" style="width:175px;">
+                <el-option
+                  v-for="dict in typeOption"
+                  :key="dict.key"
+                  :label="dict.value"
+                  :value="dict.key"
+                />
+              </el-select>
+            </el-form-item>
+            <el-form-item label="" prop="adminSubmitStatus" v-if="isSchoolAdmin">
+              <el-select v-model="queryParams.adminSubmitStatus" placeholder="状态" style="width:175px;">
+                <el-option
+                  v-for="dict in typeOption"
+                  :key="dict.key"
+                  :label="dict.value"
+                  :value="dict.key"
+                />
+              </el-select>
+            </el-form-item>
+            <p class="page-inquire-common-style-button" @click="handleQuery">查询</p>
+            <p class="page-reset-common-style-button" @click="resetQuery">重置</p>
+            <p class="page-save-common-style-button"
+               style="float: right;"
+               @click="allTableButton(2)"
+            >{{isSchoolAdmin?'批量审批':'批量提交'}}</p>
+            <!--<p class="page-submit-common-style-button"-->
+               <!--style="float: right;margin-right:20px;"-->
+               <!--@click="allTableButton(1)"-->
+            <!--&gt;批量下载</p>-->
+          </el-form>
+        </div>
+        <div class="page-conten-box page-content-right-bottom-box">
+          <el-table class="table-box" ref="multipleTable" border :data="dataList" :row-key="getRowKeys"
+                    @select-all="handleSelectionChange" @select="handleSelectionChange">
+            <el-table-column type="selection" width="50" align="center" :selectable="checkSelectable"/>
+            <el-table-column label="隐患清单编号" prop="hiddenNum" show-overflow-tooltip/>
+            <el-table-column label="学院单位" prop="deptName" width="160" show-overflow-tooltip/>
+            <el-table-column label="隐患数量" prop="hiddenCount" width="120" show-overflow-tooltip/>
+            <el-table-column label="状态"  width="120" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <div v-if="scope.row.flowStatus == 0">
+                  <span style="width:10px;height:10px;border-radius:50%;display: inline-block;margin:0 10px;" :style="scope.row.leaderSubmitStatus == 0?'background-color:#D8D8D8;':'background-color:#13CD3F;'"></span>
+                  {{scope.row.leaderSubmitStatus == 0?'待提交':'已提交'}}
+                </div>
+                <div v-if="scope.row.flowStatus == 1">
+                  <span style="width:10px;height:10px;border-radius:50%;display: inline-block;margin:0 10px;" :style="scope.row.adminSubmitStatus == 0?'background-color:#D8D8D8;':'background-color:#13CD3F;'"></span>
+                  {{scope.row.adminSubmitStatus == 0?'待审批':'已审批'}}
+                </div>
+              </template>
+            </el-table-column>
+            <el-table-column label="更新时间" prop="updateTime" width="160" show-overflow-tooltip>
+              <template slot-scope="scope">
+                <span>{{ parseTime(scope.row.updateTime,"{y}-{m}-{d} {h}:{i}") }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="更新人" prop="updateName" width="120" show-overflow-tooltip/>
+            <el-table-column label="操作" width="180" show-overflow-tooltip >
+              <template slot-scope="scope">
+                <div class="table-button-box">
+                  <p class="table-button-null"></p>
+                  <p class="table-button-p"
+                     @click="tableButton(2,scope.row)"
+                  >查看</p>
+                  <!--<p class="table-button-p"-->
+                     <!--v-if="(scope.row.leaderSubmitStatus == 0 && scope.row.flowStatus == 0 && isLeader)||(scope.row.adminSubmitStatus == 0 && scope.row.flowStatus == 1 && isSchoolAdmin)"-->
+                     <!--@click="tableButton(1,scope.row)"-->
+                  <!--&gt;编辑</p>-->
+                  <p class="table-button-p"
+                     v-if="(scope.row.leaderSubmitStatus == 0 && scope.row.flowStatus == 0 && isLeader)"
+                     @click="tableButton(1,scope.row)"
+                  >编辑</p>
+                  <p class="table-button-p"
+                     v-if="(scope.row.leaderSubmitStatus == 0 && scope.row.flowStatus == 0 && isLeader)||(scope.row.adminSubmitStatus == 0 && scope.row.flowStatus == 1 && isSchoolAdmin)"
+                     @click="tableButton(3,scope.row,scope.$index)"
+                  >{{isSchoolAdmin?'审批':'提交'}}</p>
+                  <p class="table-button-null"></p>
+                </div>
+              </template>
+            </el-table-column>
+          </el-table>
+          <pagination :page-sizes="[20, 30, 40, 50]"
+                      v-show="total>0"
+                      :total="total"
+                      :page.sync="queryParams.page"
+                      :limit.sync="queryParams.pageSize"
+                      @pagination="getList"
+          />
+        </div>
+      </div>
+    </div>
+    <checkItem :propsData="propsData" v-if="pageType === 2"></checkItem>
+    <initiateInspect v-if="pageType == 3" :initiateInspectData="initiateInspectData"></initiateInspect>
+  </div>
+</template>
+<script>
+  import {
+    securityCheckHiddenDangerTitleList,
+    securityCheckHiddenDangerList,
+    securityMemberGetCollegeList,
+    securityCheckHiddenDangerUpdate,
+    securityCheckHiddenDangerFindCurrentMemberRole,
+    securityCheckHiddenDangerBatchHiddenDangerSubmit,
+  } from '@/api/safetyCheck/index'
+  import checkItem from "@/views/safetyCheck/components/checkItem.vue";
+  import initiateInspect from "@/views/safetyCheck/components/initiateInspect/initiateInspect.vue";
+  export default {
+    name: 'index',
+    components: {
+      checkItem,
+      initiateInspect,
+    },
+    data () {
+      return {
+        //页面状态
+        pageType:1,
+        //页面遮罩
+        loading:false,
+        //学院
+        deptOption:[],
+        //分类
+        typeOption:[
+          {key:'0',value:'待提交'},
+          {key:'1',value:'已提交'},
+        ],
+        //计划查询条件
+        leftQueryParams:{
+          time:'',
+          searchValue:'',
+          page:1,
+          pageSize:20,
+        },
+        titleTotal:0,
+        //查询条件
+        queryParams:{
+          page:1,
+          pageSize:20,
+          myRelated:1,
+          deptId:null,
+          floorId:null,
+          leaderSubmitStatus :null,
+          adminSubmitStatus :null,
+          levelId :null,
+          searchValue:'',
+        },
+        //时间数据
+        dateRange:[],
+        //列表数据
+        dataList:[],
+        //数据数量
+        total:0,
+        //组件传参
+        propsData:{},
+        leftBigCheckType:"0",
+        leftCheckType:"0",
+        leftListData:[],
+        checkSetProgress:0,
+        //检查组件
+        initiateInspectData:{},
+        //选中数据
+        checkList:[],
+        //批量完成展示状态
+        memberRole:3,
+        //是否是组长
+        isLeader:false,
+        //是否是校级管理员
+        isSchoolAdmin:false,
+
+      }
+    },
+    created () {
+
+    },
+    mounted () {
+      this.getTitleList();
+    },
+    methods: {
+      //左侧清除查询按钮
+      leftClear(){
+        this.$set(this.leftQueryParams,'searchValue','');
+        this.$set(this.leftQueryParams,'time','');
+        this.getTitleList();
+      },
+      //左侧查询按钮
+      leftHandleQuery(){
+        this.getTitleList();
+      },
+      //左侧计划切换
+      leftBigCheckButton(index){
+        if(this.leftBigCheckType !== index){
+          this.$set(this,'leftBigCheckType',index);
+          this.$set(this,'leftCheckType',0);
+          this.$set(this,'checkSetProgress',this.leftListData[index].checkPlanSetVoList[0].checkSetProgress);
+          this.$set(this,'memberRole',this.leftListData[index].memberRole);
+          this.resetQuery();
+          this.securityMemberGetCollegeList();
+          this.securityCheckHiddenDangerFindCurrentMemberRole();
+        }
+      },
+      //左侧计划子级切换
+      leftCheckButton(index,bigIndex){
+        if(this.leftCheckType !== index){
+          this.$set(this,'leftCheckType',index);
+          this.$set(this,'checkSetProgress',this.leftListData[bigIndex].checkPlanSetVoList[index].checkSetProgress);
+          this.$set(this,'memberRole',this.leftListData[bigIndex].memberRole);
+          this.resetQuery();
+        }
+      },
+      //查询按钮
+      handleQuery(){
+        this.$set(this.queryParams,'page',1);
+        this.getList();
+      },
+      //重置按钮
+      resetQuery(){
+        this.$set(this,'dateRange',[])
+        this.$set(this,'queryParams',{
+          page:1,
+          pageSize:20,
+          deptId:null,
+          floorId:null,
+          leaderSubmitStatus :null,
+          adminSubmitStatus :null,
+          levelId :null,
+          searchValue:'',
+        });
+        this.getList();
+      },
+      //获取计划数据列表
+      getTitleList(){
+        securityCheckHiddenDangerTitleList(this.leftQueryParams).then(response => {
+          this.$set(this,'leftListData',response.data.records);
+          this.$set(this,'titleTotal',response.data.total);
+          this.$set(this,'leftBigCheckType',0);
+          this.$set(this,'leftCheckType',0);
+          this.resetQuery();
+          if(response.data.records[0]){
+            this.$set(this,'checkSetProgress',this.leftListData[0].checkPlanSetVoList[0].checkSetProgress);
+            this.$set(this,'memberRole',this.leftListData[0].memberRole);
+            this.securityMemberGetCollegeList();
+            this.securityCheckHiddenDangerFindCurrentMemberRole();
+          }
+        });
+      },
+      getTitleListTwo(){
+        securityCheckHiddenDangerTitleList(this.leftQueryParams).then(response => {
+          this.$set(this,'leftListData',response.data.records);
+          this.$set(this,'titleTotal',response.data.total);
+          this.getList();
+        });
+      },
+      //提交审批
+      securityCheckHiddenDangerUpdate(item,index){
+        console.log(index)
+        let obj = {
+          hiddenId:item.hiddenId,
+        }
+        if(item.flowStatus == 1){
+          obj.adminSubmitStatus = 1;
+          obj.flowStatus = 1;
+        }else if(item.flowStatus == 0){
+          obj.leaderSubmitStatus = 1;
+          obj.flowStatus = 1;
+        }
+        securityCheckHiddenDangerUpdate(obj).then(response => {
+          this.msgSuccess(response.message)
+          if(this.listForEstimate(this.leftListData[this.leftBigCheckType].checkPlanSetVoList,index) == 1){
+            this.getTitleList();
+          }else{
+            this.getList();
+          }
+        })
+      },
+      //批量提交审批
+      securityCheckHiddenDangerBatchHiddenDangerSubmit(){
+        let obj = {
+          hiddenIds:this.checkList,
+        };
+        if(!this.isSchoolAdmin){
+          //组长
+          obj.flowStatus = 1;
+          obj.leaderSubmitStatus = 1;
+        }else{
+          //管理员
+          obj.flowStatus = 1;
+          obj.adminSubmitStatus = 1;
+        }
+        securityCheckHiddenDangerBatchHiddenDangerSubmit(obj).then(response => {
+          this.$set(this,'checkList',[]);
+          this.$refs.multipleTable.clearSelection();
+          this.msgSuccess(response.message)
+          this.getTitleList();
+        })
+      },
+      //获取数据列表
+      getList(){
+        if(!this.leftListData[0]){
+          this.$set(this,'dataList',[]);
+          this.$set(this,'total',0);
+          return
+        }
+        this.$set(this,'loading',true);
+        let obj = {
+          planId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planId,
+          planSetId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planSetId,
+          page:this.queryParams.page,
+          pageSize:this.queryParams.pageSize,
+          deptId:this.queryParams.deptId,
+        }
+        if(!this.isSchoolAdmin){
+          obj.leaderSubmitStatus = this.queryParams.leaderSubmitStatus;
+        }else{
+          obj.adminSubmitStatus = this.queryParams.adminSubmitStatus;
+        }
+        securityCheckHiddenDangerList(obj).then(response => {
+          this.$set(this,'loading',false);
+          this.$set(this,'dataList',response.data.records);
+          this.$set(this,'total',response.data.total);
+        });
+      },
+      //操作按钮
+      tableButton(type,row,index){
+        let self = this;
+        if(type == 1){
+          //编辑
+          const route = this.$router.resolve({
+            path: '/schoolHiddenDangerAdd',
+            query: {
+              type: 'edit',
+              hiddenId:row.hiddenId
+            }
+          });
+          window.open(route.href, '_blank');
+        }else if(type == 2){
+          //查看
+          const route = this.$router.resolve({
+            path: '/schoolHiddenDangerAdd',
+            query: {
+              type: 'look',
+              hiddenId:row.hiddenId
+            }
+          });
+          window.open(route.href, '_blank');
+        }else if(type == 3){
+          //提交
+          this.$confirm(`是否确认提交?`, "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }).then(async () => {
+            self.securityCheckHiddenDangerUpdate(row,index);
+          }).catch(() => {
+
+          })
+        }
+      },
+      //批量操作
+      allTableButton(type){
+        let self = this;
+        if(!this.checkList[0]){
+          this.msgError('请勾选数据')
+          return
+        }
+        if(type == 1){
+          //批量下载
+          this.$set(this,'checkList',[]);
+          this.$refs.multipleTable.clearSelection();
+        }else if(type == 2){
+          //批量提交
+          if(!this.checkList[0]){
+            this.msgError('请勾选数据')
+            return
+          }
+          this.$confirm(`是否确认批量提交?`, "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }).then(async () => {
+            self.securityCheckHiddenDangerBatchHiddenDangerSubmit();
+          }).catch(() => {
+
+          })
+        }
+      },
+      /*********************************** 学院/楼栋/分类/分级 ***********************************/
+      //学院下拉列表
+      securityMemberGetCollegeList(){
+        securityMemberGetCollegeList({planId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planId}).then(response => {
+          this.$set(this,'deptOption',response.data);
+        });
+      },
+      //查询当前用户权限范围
+      securityCheckHiddenDangerFindCurrentMemberRole(){
+        securityCheckHiddenDangerFindCurrentMemberRole({planId:this.leftListData[this.leftBigCheckType].checkPlanSetVoList[this.leftCheckType].planId}).then(response => {
+          this.$set(this,'isLeader',response.data.isLeader);
+          this.$set(this,'isSchoolAdmin',response.data.isSchoolAdmin);
+        });
+      },
+      /*===记录勾选数据===
+        需要再el-table 添加  :row-key="getRowKeys"
+        需要在selection 添加 :reserve-selection="true"
+      */
+      getRowKeys(row) {
+        return row.manageId
+      },
+      // 多选框选中数据
+      handleSelectionChange(selection) {
+        this.$set(this,'checkList',selection.map(item => item.hiddenId));
+      },
+      //勾选判定
+      checkSelectable(row, index) {
+        return row.adminSubmitStatus != 1;
+      },
+      //数据判断方法
+      listForEstimate(list,index){
+        if(!list[1]){
+          //只有一条数据
+          return 1
+        }else if(list.length-1 == index){
+          //当前数据是数组最后一条数据
+          return 2
+        }else {
+          //list 拥有多条数据 并且当前数据不是最后一条
+          return 3
+        }
+      },
+    },
+  }
+</script>
+<style scoped lang="scss">
+  .schoolHiddenDangerList{
+    .schoolHiddenDangerListPage{
+      overflow: hidden;
+      display: flex;
+      flex-direction: row;
+      flex:1;
+
+      .page-content-left-box{
+        width: 480px;
+        display: flex;
+        flex-direction: column;
+        overflow: hidden;
+        margin:20px 0 20px 20px;
+        padding-right:10px;
+        .left-max-list-box{
+          flex:1;
+          padding-right:10px;
+          .left-list-for-max-big-box{
+            .left-list-title-box{
+              cursor: pointer;
+              display: flex;
+              p{
+                height:30px;
+                line-height:30px;
+                margin:15px 0;
+              }
+              p:nth-child(1){
+                font-size:16px;
+                width:30px;
+              }
+              p:nth-child(2){
+                font-size:16px;
+                flex:1;
+                /*单行省略号*/
+                display:block;
+                overflow:hidden;
+                text-overflow:ellipsis;
+                white-space:nowrap;
+              }
+              p:nth-child(3){
+                font-size:14px;
+                width:80px;
+                height:30px;
+                text-align: center;
+                color:#fff;
+                background-color: #0183FA;
+                border-radius:4px;
+              }
+            }
+            .left-list-box{
+              .left-list-for-box{
+                cursor: pointer;
+                display: flex;
+                height:70px;
+                background-color: #F5F5F5;
+                padding:5px 23px;
+                .left-list-text-box{
+                  width:240px;
+                  p{
+                    height:30px;
+                    line-height: 30px;
+                    font-size:16px;
+                    /*单行省略号*/
+                    display:block;
+                    overflow:hidden;
+                    text-overflow:ellipsis;
+                    white-space:nowrap;
+                  }
+                  p:nth-child(2){
+                    color:#666666;
+                  }
+                }
+                .left-list-progress-box{
+                  flex:1;
+                  padding-top:15px;
+                  ::v-deep .el-progress-bar{
+                    margin-right: -62px;
+                  }
+                }
+              }
+              .check-left-list-for-box{
+                background: rgba(1,131,250,0.1);
+              }
+            }
+          }
+          .left-list-for-null-p{
+            text-align: center;
+            line-height:400px;
+            color:#999;
+          }
+        }
+      }
+      .page-content-center-box{
+        margin:20px 0;
+        border-right:1px dashed #dedede;
+      }
+      .page-content-right-box{
+        display: flex;
+        flex-direction: column;
+        overflow: hidden;
+        flex:1;
+        .page-content-right-bottom-box{
+          display: flex;
+          flex-direction: column;
+          overflow: hidden;
+          flex:1;
+          padding:0 20px 20px;
+          .colorA{
+            color:#FA4A04;
+          }
+          .colorB{
+            color:#0484FA;
+          }
+          .colorC{
+            color:#039C06;
+          }
+        }
+      }
+      .table-school-college-toggle-box{
+        overflow: hidden;
+        display: inline-block;
+        margin-right:10px;
+        p{
+          display: inline-block;
+          text-align: center;
+          width:80px;
+          line-height:40px;
+          height:40px;
+          color:#333;
+          background-color: #fff;
+          border:1px solid #E0E0E0;
+          font-size:14px;
+          cursor: pointer;
+        }
+        p:nth-child(1){
+          border-top-left-radius: 4px;
+          border-bottom-left-radius: 4px;
+          /*border-right:none;*/
+        }
+        p:nth-child(3){
+          border-top-right-radius: 4px;
+          border-bottom-right-radius: 4px;
+          /*border-left:none;*/
+        }
+        .p-check{
+          border:1px solid #0183FA;
+          background-color: #0183FA;
+          color:#fff;
+        }
+      }
+      .form-button-max-big-box-me{
+        display: inline-block;
+        overflow: hidden;
+        margin-right:10px;
+        .form-button-big-box-me{
+          display: flex;
+          div{
+            position: relative;
+            height:40px;
+            width:100px;
+            line-height: 40px;
+            text-align: center;
+            color:#999;
+            font-size:14px;
+            border:1px solid #999;
+            border-radius:4px;
+            font-weight:500;
+            cursor: pointer;
+            .icon-p-me{
+              width:15px;
+              height:15px;
+              line-height:15px;
+              text-align: center;
+              position: absolute;
+              right:0;
+              bottom:0;
+              color:#fff;
+              background: #0183fa;
+              border-top-left-radius:4px;
+            }
+          }
+          .checkDiv-me{
+            color:#0183FA!important;
+            border:1px solid #0183FA!important;
+          }
+        }
+      }
+
+    }
+  }
+</style>