|
@@ -1,9 +1,9 @@
|
|
|
<template>
|
|
|
<div class="page-container snapshot-snapshotInfo">
|
|
|
<div class="page-top-title-box">
|
|
|
- <p class="page-top-title-name-p">{{addForm.id?'编辑':'新增'}}</p>
|
|
|
+ <p class="page-top-title-name-p">{{lookInfoType?'详情':(addForm.photoId?'编辑':'新增')}}</p>
|
|
|
<p class="page-top-title-out-p" @click="backPage">返回</p>
|
|
|
- <p class="page-top-title-add-p" @click="submitForm">提交</p>
|
|
|
+ <p class="page-top-title-add-p" v-if="!lookInfoType" @click="submitForm">提交</p>
|
|
|
</div>
|
|
|
<div class="content-box scrollbar-box">
|
|
|
<el-form class="add-form-box" :model="addForm" ref="form" :rules="rules" label-width="104px">
|
|
@@ -13,11 +13,11 @@
|
|
|
</p>
|
|
|
<div v-if="itemShowType_1" class="show-box">
|
|
|
<div class="content-flex-box">
|
|
|
- <el-form-item label="实验室" prop="data1">
|
|
|
+ <el-form-item label="实验室" prop="subId">
|
|
|
<el-select
|
|
|
:disabled="lookInfoType"
|
|
|
style="width:300px;"
|
|
|
- v-model="addForm.data1"
|
|
|
+ v-model="addForm.subId"
|
|
|
filterable
|
|
|
remote
|
|
|
clearable
|
|
@@ -25,7 +25,7 @@
|
|
|
@change="selectChange"
|
|
|
@clear="selectClear"
|
|
|
placeholder="搜索选择实验室"
|
|
|
- :remote-method="subjectList">
|
|
|
+ :remote-method="laboratorySubRelInfoGetRelList">
|
|
|
<el-option
|
|
|
v-for="item in subOptions"
|
|
|
:key="item.subId"
|
|
@@ -37,21 +37,27 @@
|
|
|
<div class="right-text-box">
|
|
|
<p class="right-text-name-p" style="width:138px;">分级分类</p>
|
|
|
<div class="right-text-title-box">
|
|
|
- <p>{{addForm.data2}}</p>
|
|
|
+ <p v-if="addForm.classLevelName||addForm.classTypeNames" style="color:#333;">
|
|
|
+ {{addForm.classLevelName}}{{addForm.classLevelName&&addForm.classTypeNames?' | ':''}}{{addForm.classTypeNames}}
|
|
|
+ </p>
|
|
|
+ <p v-else="addForm.classLevelName||addForm.classTypeNames" style="color:#999;">搜索选择实验室</p>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="right-text-box">
|
|
|
<p class="right-text-name-p" style="width:138px;">学院单位</p>
|
|
|
<div class="right-text-title-box">
|
|
|
- <p>{{addForm.data3}}</p>
|
|
|
+ <p :style="!addForm.deptName?'color:#999;':'color:#333;'">{{addForm.deptName?addForm.deptName:'搜索选择实验室'}}</p>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="content-flex-box">
|
|
|
<div class="right-text-box">
|
|
|
- <p class="right-text-name-p">学院单位</p>
|
|
|
+ <p class="right-text-name-p">楼栋楼层</p>
|
|
|
<div class="right-text-title-box">
|
|
|
- <p>{{addForm.data4}}</p>
|
|
|
+ <p v-if="addForm.buildName||addForm.floorName" style="color:#333;">
|
|
|
+ {{addForm.buildName}}{{addForm.buildName&&addForm.floorName?'-':''}}{{addForm.floorName}}
|
|
|
+ </p>
|
|
|
+ <p v-else="addForm.buildName||addForm.floorName" style="color:#999;">搜索选择实验室</p>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -61,23 +67,29 @@
|
|
|
<span :class="itemShowType_2?'el-icon-arrow-down':'el-icon-arrow-up'" @click="itemShowButton(2)"></span>
|
|
|
</p>
|
|
|
<div v-if="itemShowType_2" class="show-box">
|
|
|
- <el-form-item label="名称" prop="data3">
|
|
|
+ <el-form-item label="检查项目" prop="hazardCheckId">
|
|
|
<el-cascader
|
|
|
+ :disabled="lookInfoType"
|
|
|
+ clearable
|
|
|
+ placeholder="请选择检查项目"
|
|
|
style="width:704px;"
|
|
|
- v-model="addForm.data3"
|
|
|
+ v-model="addForm.hazardCheckId"
|
|
|
:options="options"
|
|
|
+ :props="{ value: 'id', label: 'labelName',emitPath:false }"
|
|
|
@change="handleChange"></el-cascader>
|
|
|
</el-form-item>
|
|
|
<div class="right-text-box">
|
|
|
<p class="right-text-name-p">检查要点</p>
|
|
|
<div class="right-text-title-box" style="min-height: 80px;width:704px;">
|
|
|
- <p>{{addForm.data4}}</p>
|
|
|
+ <p :style="!addForm.hazardCheckPoint?'color:#999;':'color:#333;'">{{addForm.hazardCheckPoint?addForm.hazardCheckPoint:'请选择检查项目'}}</p>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="right-text-box">
|
|
|
<p class="right-text-name-p">隐患等级</p>
|
|
|
<div class="right-text-title-box" style="width:301px;">
|
|
|
- <p>{{addForm.data5}}</p>
|
|
|
+ <p :style="!addForm.hazardLevel?'color:#999;':'color:#333;'">
|
|
|
+ {{addForm.hazardLevel==1?'轻微隐患':(addForm.hazardLevel==2?'一般隐患':(addForm.hazardLevel==3?'重大隐患':'请选择检查项目'))}}
|
|
|
+ </p>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -86,17 +98,18 @@
|
|
|
<span :class="itemShowType_3?'el-icon-arrow-down':'el-icon-arrow-up'" @click="itemShowButton(3)"></span>
|
|
|
</p>
|
|
|
<div v-if="itemShowType_3" class="show-box">
|
|
|
- <el-form-item label="隐患描述" prop="formData5">
|
|
|
+ <el-form-item label="隐患描述" prop="hazardDescribe">
|
|
|
<el-input placeholder="请输入隐患描述" maxLength='200' type="textarea" style="width:704px;"
|
|
|
- resize="none" v-model="addForm.formData5" show-word-limit :rows="3"></el-input>
|
|
|
+ :disabled="lookInfoType"
|
|
|
+ resize="none" v-model="addForm.hazardDescribe" show-word-limit :rows="3"></el-input>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="现场照片" prop="imgDtoList">
|
|
|
<div class="snapshotManagement-for-img-box" v-for="(img,imgIndex) in addForm.imgDtoList" :key="imgIndex">
|
|
|
<img class="for-img" :src="img.fileUrl" @click="fullScreenViewClick(addForm.imgDtoList,imgIndex)">
|
|
|
- <p class="for-del-button el-icon-circle-close" @click="delImg(imgIndex)"></p>
|
|
|
+ <p class="for-del-button el-icon-circle-close" v-if="!lookInfoType" @click="delImg(imgIndex)"></p>
|
|
|
</div>
|
|
|
<el-upload
|
|
|
- v-if="addForm.imgDtoList.length<6"
|
|
|
+ v-if="addForm.imgDtoList.length<6&&!lookInfoType"
|
|
|
style="display: inline-block;overflow: hidden"
|
|
|
class="avatar-uploader"
|
|
|
:action="uploadImgUrl"
|
|
@@ -106,12 +119,11 @@
|
|
|
:before-upload="(res)=>beforeAvatarUpload(res)">
|
|
|
<p class="el-icon-plus up-img-p" style="display: inline-block"></p>
|
|
|
</el-upload>
|
|
|
- <p class="up-img-text">支持jpg/png/bmp/gif格式,且不超过2M,最多上传6张</p>
|
|
|
+ <p class="up-img-text" v-if="!lookInfoType">支持jpg/png/bmp/gif格式,且不超过2M,最多上传6张</p>
|
|
|
</el-form-item>
|
|
|
- </div><!--历史记录-->
|
|
|
- <history-records-component ref="historyRecordsComponent" :historyRecordsComponentPropsData="historyRecordsComponentPropsData"></history-records-component>
|
|
|
+ </div>
|
|
|
<!--整改-->
|
|
|
- <rectification-component ref="rectificationComponent" :recheckComponentPropsData="recheckComponentPropsData"></rectification-component>
|
|
|
+ <rectification-component v-if="infoType === 'rectify'" ref="rectificationComponent" :recheckComponentPropsData="recheckComponentPropsData"></rectification-component>
|
|
|
</el-form>
|
|
|
</div>
|
|
|
<fullScreenView :fullScreenViewProps="fullScreenViewProps" ref="fullScreenView"></fullScreenView>
|
|
@@ -120,8 +132,15 @@
|
|
|
|
|
|
<script>
|
|
|
import { getToken } from "@/utils/auth";
|
|
|
+ import {
|
|
|
+ securityCheckPhotoDetail,
|
|
|
+ securityCheckOptionList,
|
|
|
+ securityCheckPhotoMyAdd,
|
|
|
+ } from '@/api/safetyCheck/indexDemoOne'
|
|
|
+ import {
|
|
|
+ laboratorySubRelInfoGetRelList,
|
|
|
+ } from '@/api/commonality/noPermission'
|
|
|
import fullScreenView from "@/components/fullScreenView/fullScreenView.vue";
|
|
|
- import historyRecordsComponent from "./initiateInspect/historyRecordsComponent.vue";
|
|
|
import rectificationComponent from "./initiateInspect/rectificationComponent.vue";
|
|
|
//import { getDicts } from "@/api/commonality/noPermission";
|
|
|
//import { systemUserSelect } from "@/api/commonality/permission";
|
|
@@ -130,7 +149,6 @@
|
|
|
name: 'snapshotInfo',
|
|
|
components: {
|
|
|
fullScreenView,
|
|
|
- historyRecordsComponent,
|
|
|
rectificationComponent,
|
|
|
},
|
|
|
props:{
|
|
@@ -147,6 +165,8 @@
|
|
|
fullScreenViewProps:[],
|
|
|
//详情模式
|
|
|
lookInfoType:false,
|
|
|
+ //页面状态 add.新增
|
|
|
+ infoType:'',
|
|
|
//实验室列表
|
|
|
subOptions:[],
|
|
|
//学院列表
|
|
@@ -159,22 +179,40 @@
|
|
|
levelOptions: [],
|
|
|
//提交表单
|
|
|
addForm:{
|
|
|
- data1Id:'',
|
|
|
- data1Name:'',
|
|
|
+ deptId:'',
|
|
|
+ deptName:'',
|
|
|
+ subId:'',
|
|
|
+ subName:'',
|
|
|
+ subRoom:'',
|
|
|
+ buildId:'',
|
|
|
+ buildName:'',
|
|
|
+ floorId:'',
|
|
|
+ floorName:'',
|
|
|
+ typeId:'',
|
|
|
+ classTypeNames:'',
|
|
|
+ levelId:'',
|
|
|
+ classLevelName:'',
|
|
|
+ hazardCheckId1:'',
|
|
|
+ hazardCheckName1:'',
|
|
|
+ hazardCheckCode1:'',
|
|
|
+ hazardCheckId2:'',
|
|
|
+ hazardCheckName2:'',
|
|
|
+ hazardCheckCode2:'',
|
|
|
+ hazardCheckId:'',
|
|
|
+ hazardCheckName:'',
|
|
|
+ hazardCheckCode:'',
|
|
|
+ hazardCheckPoint:'',
|
|
|
+ hazardLevel:'',
|
|
|
+ hazardDescribe:'',
|
|
|
imgDtoList:[],
|
|
|
},
|
|
|
rules:{
|
|
|
- formData1: [
|
|
|
- { required: true, message: "请选择检查项目", trigger: "blur" },
|
|
|
- { required: true, message: "请选择检查项目", validator: this.spaceJudgment, trigger: "blur" }
|
|
|
- ],
|
|
|
- formData4: [
|
|
|
- { required: true, message: "请选择检查结果", trigger: "blur" },
|
|
|
- { required: true, message: "请选择检查结果", validator: this.spaceJudgment, trigger: "blur" }
|
|
|
+ subId: [
|
|
|
+ { required: true, message: "搜索选择实验室", trigger: "blur" },
|
|
|
],
|
|
|
- formData5: [
|
|
|
+ hazardDescribe: [
|
|
|
{ required: true, message: "请输入隐患描述", trigger: "blur" },
|
|
|
- { required: true, message: "请输入隐患描述", validator: this.spaceJudgment, trigger: "blur" }
|
|
|
+ { required: true, message: '请输入隐患描述', validator: this.spaceJudgment, trigger: "blur" }
|
|
|
],
|
|
|
imgDtoList: [
|
|
|
{ required: true, message: "请上传现场照片", trigger: "blur" },
|
|
@@ -184,230 +222,123 @@
|
|
|
itemShowType_1:true,
|
|
|
itemShowType_2:true,
|
|
|
itemShowType_3:true,
|
|
|
- options:[
|
|
|
- {
|
|
|
- value: 'zhinan',
|
|
|
- label: '指南',
|
|
|
- children: [{
|
|
|
- value: 'shejiyuanze',
|
|
|
- label: '设计原则',
|
|
|
- children: [{
|
|
|
- value: 'yizhi',
|
|
|
- label: '一致'
|
|
|
- }, {
|
|
|
- value: 'fankui',
|
|
|
- label: '反馈'
|
|
|
- }, {
|
|
|
- value: 'xiaolv',
|
|
|
- label: '效率'
|
|
|
- }, {
|
|
|
- value: 'kekong',
|
|
|
- label: '可控'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'daohang',
|
|
|
- label: '导航',
|
|
|
- children: [{
|
|
|
- value: 'cexiangdaohang',
|
|
|
- label: '侧向导航'
|
|
|
- }, {
|
|
|
- value: 'dingbudaohang',
|
|
|
- label: '顶部导航'
|
|
|
- }]
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'zujian',
|
|
|
- label: '组件',
|
|
|
- children: [{
|
|
|
- value: 'basic',
|
|
|
- label: 'Basic',
|
|
|
- children: [{
|
|
|
- value: 'layout',
|
|
|
- label: 'Layout 布局'
|
|
|
- }, {
|
|
|
- value: 'color',
|
|
|
- label: 'Color 色彩'
|
|
|
- }, {
|
|
|
- value: 'typography',
|
|
|
- label: 'Typography 字体'
|
|
|
- }, {
|
|
|
- value: 'icon',
|
|
|
- label: 'Icon 图标'
|
|
|
- }, {
|
|
|
- value: 'button',
|
|
|
- label: 'Button 按钮'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'form',
|
|
|
- label: 'Form',
|
|
|
- children: [{
|
|
|
- value: 'radio',
|
|
|
- label: 'Radio 单选框'
|
|
|
- }, {
|
|
|
- value: 'checkbox',
|
|
|
- label: 'Checkbox 多选框'
|
|
|
- }, {
|
|
|
- value: 'input',
|
|
|
- label: 'Input 输入框'
|
|
|
- }, {
|
|
|
- value: 'input-number',
|
|
|
- label: 'InputNumber 计数器'
|
|
|
- }, {
|
|
|
- value: 'select',
|
|
|
- label: 'Select 选择器'
|
|
|
- }, {
|
|
|
- value: 'cascader',
|
|
|
- label: 'Cascader 级联选择器'
|
|
|
- }, {
|
|
|
- value: 'switch',
|
|
|
- label: 'Switch 开关'
|
|
|
- }, {
|
|
|
- value: 'slider',
|
|
|
- label: 'Slider 滑块'
|
|
|
- }, {
|
|
|
- value: 'time-picker',
|
|
|
- label: 'TimePicker 时间选择器'
|
|
|
- }, {
|
|
|
- value: 'date-picker',
|
|
|
- label: 'DatePicker 日期选择器'
|
|
|
- }, {
|
|
|
- value: 'datetime-picker',
|
|
|
- label: 'DateTimePicker 日期时间选择器'
|
|
|
- }, {
|
|
|
- value: 'upload',
|
|
|
- label: 'Upload 上传'
|
|
|
- }, {
|
|
|
- value: 'rate',
|
|
|
- label: 'Rate 评分'
|
|
|
- }, {
|
|
|
- value: 'form',
|
|
|
- label: 'Form 表单'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'data',
|
|
|
- label: 'Data',
|
|
|
- children: [{
|
|
|
- value: 'table',
|
|
|
- label: 'Table 表格'
|
|
|
- }, {
|
|
|
- value: 'tag',
|
|
|
- label: 'Tag 标签'
|
|
|
- }, {
|
|
|
- value: 'progress',
|
|
|
- label: 'Progress 进度条'
|
|
|
- }, {
|
|
|
- value: 'tree',
|
|
|
- label: 'Tree 树形控件'
|
|
|
- }, {
|
|
|
- value: 'pagination',
|
|
|
- label: 'Pagination 分页'
|
|
|
- }, {
|
|
|
- value: 'badge',
|
|
|
- label: 'Badge 标记'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'notice',
|
|
|
- label: 'Notice',
|
|
|
- children: [{
|
|
|
- value: 'alert',
|
|
|
- label: 'Alert 警告'
|
|
|
- }, {
|
|
|
- value: 'loading',
|
|
|
- label: 'Loading 加载'
|
|
|
- }, {
|
|
|
- value: 'message',
|
|
|
- label: 'Message 消息提示'
|
|
|
- }, {
|
|
|
- value: 'message-box',
|
|
|
- label: 'MessageBox 弹框'
|
|
|
- }, {
|
|
|
- value: 'notification',
|
|
|
- label: 'Notification 通知'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'navigation',
|
|
|
- label: 'Navigation',
|
|
|
- children: [{
|
|
|
- value: 'menu',
|
|
|
- label: 'NavMenu 导航菜单'
|
|
|
- }, {
|
|
|
- value: 'tabs',
|
|
|
- label: 'Tabs 标签页'
|
|
|
- }, {
|
|
|
- value: 'breadcrumb',
|
|
|
- label: 'Breadcrumb 面包屑'
|
|
|
- }, {
|
|
|
- value: 'dropdown',
|
|
|
- label: 'Dropdown 下拉菜单'
|
|
|
- }, {
|
|
|
- value: 'steps',
|
|
|
- label: 'Steps 步骤条'
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'others',
|
|
|
- label: 'Others',
|
|
|
- children: [{
|
|
|
- value: 'dialog',
|
|
|
- label: 'Dialog 对话框'
|
|
|
- }, {
|
|
|
- value: 'tooltip',
|
|
|
- label: 'Tooltip 文字提示'
|
|
|
- }, {
|
|
|
- value: 'popover',
|
|
|
- label: 'Popover 弹出框'
|
|
|
- }, {
|
|
|
- value: 'card',
|
|
|
- label: 'Card 卡片'
|
|
|
- }, {
|
|
|
- value: 'carousel',
|
|
|
- label: 'Carousel 走马灯'
|
|
|
- }, {
|
|
|
- value: 'collapse',
|
|
|
- label: 'Collapse 折叠面板'
|
|
|
- }]
|
|
|
- }]
|
|
|
- }, {
|
|
|
- value: 'ziyuan',
|
|
|
- label: '资源',
|
|
|
- children: [{
|
|
|
- value: 'axure',
|
|
|
- label: 'Axure Components'
|
|
|
- }, {
|
|
|
- value: 'sketch',
|
|
|
- label: 'Sketch Templates'
|
|
|
- }, {
|
|
|
- value: 'jiaohu',
|
|
|
- label: '组件交互文档'
|
|
|
- }]
|
|
|
- }
|
|
|
- ],
|
|
|
+ options:[],
|
|
|
//历史记录组件数据
|
|
|
historyRecordsComponentPropsData:{},
|
|
|
- rectificationComponentPropsData:{},
|
|
|
-
|
|
|
+ recheckComponentPropsData:{},
|
|
|
}
|
|
|
},
|
|
|
created(){
|
|
|
- // this.initialize();
|
|
|
+ this.securityCheckOptionList();
|
|
|
+ this.initialize();
|
|
|
},
|
|
|
mounted(){
|
|
|
|
|
|
},
|
|
|
methods:{
|
|
|
+ //初始化
|
|
|
+ initialize(){
|
|
|
+ if(this.propsData.showType){
|
|
|
+ this.$set(this,'lookInfoType',true);
|
|
|
+ this.securityCheckPhotoDetail();
|
|
|
+ }else{
|
|
|
+ this.$set(this,'lookInfoType',false);
|
|
|
+ if(this.propsData.photoId){
|
|
|
+ this.securityCheckPhotoDetail();
|
|
|
+ this.$set(this,'infoType','rectify');
|
|
|
+ }else{
|
|
|
+ this.$set(this,'infoType','add');
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ //上报详情接口
|
|
|
+ securityCheckPhotoDetail(){
|
|
|
+ securityCheckPhotoDetail({photoId:this.propsData.photoId}).then(response => {
|
|
|
+ response.data.imgDtoList = response.data.yhDtoList;
|
|
|
+ this.$set(this,'addForm',response.data);
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //查询检查项列表
|
|
|
+ securityCheckOptionList(){
|
|
|
+ securityCheckOptionList({}).then( response => {
|
|
|
+ this.$set(this,'options',response.data);
|
|
|
+ this.getCascaderData(this.options)
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //联级选择器数据处理
|
|
|
+ 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].level == 1 || list[i].level == 2){
|
|
|
+ self.getCascaderData(list[i].children)
|
|
|
+ }else{
|
|
|
+ delete list[i].children
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
// 返回按钮
|
|
|
backPage(){
|
|
|
this.$parent.tableButton(6);
|
|
|
},
|
|
|
/** 提交按钮 */
|
|
|
submitForm() {
|
|
|
+ let self = this;
|
|
|
this.$refs["form"].validate(valid => {
|
|
|
if (valid) {
|
|
|
-
|
|
|
+ this.$confirm('是否确认提交?', "警告", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning"
|
|
|
+ }).then(function() {
|
|
|
+ }).then(() => {
|
|
|
+ securityCheckPhotoMyAdd(self.addForm).then(response => {
|
|
|
+ self.msgSuccess(response.message)
|
|
|
+ self.$parent.tableButton(6);
|
|
|
+ });
|
|
|
+ }).catch(() => {});
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
handleChange(value) {
|
|
|
- console.log(value);
|
|
|
+ let self = this;
|
|
|
+ if(value){
|
|
|
+ for(let i=0;i<self.options.length;i++){
|
|
|
+ if(self.options[i].children){
|
|
|
+ for(let o=0;o<self.options[i].children.length;o++){
|
|
|
+ if(self.options[i].children[o].children){
|
|
|
+ for(let x=0;x<self.options[i].children[o].children.length;x++){
|
|
|
+ if (value == self.options[i].children[o].children[x].id){
|
|
|
+ self.$set(self.addForm,'hazardCheckId1',self.options[i].id);
|
|
|
+ self.$set(self.addForm,'hazardCheckName1',self.options[i].name);
|
|
|
+ self.$set(self.addForm,'hazardCheckCode1',self.options[i].code);
|
|
|
+ self.$set(self.addForm,'hazardCheckId2',self.options[i].children[o].id);
|
|
|
+ self.$set(self.addForm,'hazardCheckName2',self.options[i].children[o].name);
|
|
|
+ self.$set(self.addForm,'hazardCheckCode2',self.options[i].children[o].code);
|
|
|
+ self.$set(self.addForm,'hazardCheckId',self.options[i].children[o].children[x].id);
|
|
|
+ self.$set(self.addForm,'hazardCheckName',self.options[i].children[o].children[x].name);
|
|
|
+ self.$set(self.addForm,'hazardCheckCode',self.options[i].children[o].children[x].code);
|
|
|
+ self.$set(self.addForm,'hazardCheckPoint',self.options[i].children[o].children[x].mainPoint);
|
|
|
+ self.$set(self.addForm,'hazardLevel',self.options[i].children[o].children[x].level);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ self.$set(self.addForm,'hazardCheckId1','');
|
|
|
+ self.$set(self.addForm,'hazardCheckName1','');
|
|
|
+ self.$set(self.addForm,'hazardCheckCode1','');
|
|
|
+ self.$set(self.addForm,'hazardCheckId2','');
|
|
|
+ self.$set(self.addForm,'hazardCheckName2','');
|
|
|
+ self.$set(self.addForm,'hazardCheckCode2','');
|
|
|
+ self.$set(self.addForm,'hazardCheckId','');
|
|
|
+ self.$set(self.addForm,'hazardCheckName','');
|
|
|
+ self.$set(self.addForm,'hazardCheckCode','');
|
|
|
+ self.$set(self.addForm,'hazardCheckPoint','');
|
|
|
+ self.$set(self.addForm,'hazardLevel','');
|
|
|
+ }
|
|
|
},
|
|
|
//子项展开隐藏按钮
|
|
|
itemShowButton(type){
|
|
@@ -420,8 +351,8 @@
|
|
|
}
|
|
|
},
|
|
|
//懒加载实验室
|
|
|
- subjectList(e){
|
|
|
- subjectList({subName:e}).then(response => {
|
|
|
+ laboratorySubRelInfoGetRelList(e){
|
|
|
+ laboratorySubRelInfoGetRelList({searchValue:e}).then(response => {
|
|
|
this.subOptions = response.data;
|
|
|
});
|
|
|
},
|
|
@@ -430,15 +361,38 @@
|
|
|
let self = this;
|
|
|
for(let i=0;i<self.subOptions.length;i++){
|
|
|
if(self.subOptions[i].subId == e){
|
|
|
- self.$set(self.addForm,"data1Id",self.subOptions[i].subId);
|
|
|
- self.$set(self.addForm,"data1Name",self.subOptions[i].subName);
|
|
|
+ self.$set(self.addForm,"deptId",self.subOptions[i].deptId);
|
|
|
+ self.$set(self.addForm,"deptName",self.subOptions[i].deptName);
|
|
|
+ self.$set(self.addForm,"subId",self.subOptions[i].subId);
|
|
|
+ self.$set(self.addForm,"subName",self.subOptions[i].subName);
|
|
|
+ self.$set(self.addForm,"subRoom",self.subOptions[i].subRoom);
|
|
|
+ self.$set(self.addForm,"buildId",self.subOptions[i].buildId);
|
|
|
+ self.$set(self.addForm,"buildName",self.subOptions[i].buildName);
|
|
|
+ self.$set(self.addForm,"floorId",self.subOptions[i].floorId);
|
|
|
+ self.$set(self.addForm,"floorName",self.subOptions[i].floorName);
|
|
|
+ self.$set(self.addForm,"typeId",self.subOptions[i].typeId);
|
|
|
+ self.$set(self.addForm,"classTypeNames",self.subOptions[i].classTypeNames);
|
|
|
+ self.$set(self.addForm,"levelId",self.subOptions[i].levelId);
|
|
|
+ self.$set(self.addForm,"classLevelName",self.subOptions[i].classLevelName);
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
//实验室清除
|
|
|
selectClear(){
|
|
|
- this.$set(this.addForm,"data1Id",'');
|
|
|
- this.$set(this.addForm,"data1Name",'');
|
|
|
+ let self = this;
|
|
|
+ self.$set(self.addForm,"deptId",'');
|
|
|
+ self.$set(self.addForm,"deptName",'');
|
|
|
+ self.$set(self.addForm,"subId",'');
|
|
|
+ self.$set(self.addForm,"subName",'');
|
|
|
+ self.$set(self.addForm,"subRoom",'');
|
|
|
+ self.$set(self.addForm,"buildId",'');
|
|
|
+ self.$set(self.addForm,"buildName",'');
|
|
|
+ self.$set(self.addForm,"floorId",'');
|
|
|
+ self.$set(self.addForm,"floorName",'');
|
|
|
+ self.$set(self.addForm,"typeId",'');
|
|
|
+ self.$set(self.addForm,"classTypeNames",'');
|
|
|
+ self.$set(self.addForm,"levelId",'');
|
|
|
+ self.$set(self.addForm,"classLevelName",'');
|
|
|
},
|
|
|
/*==========上传相关==========*/
|
|
|
handleAvatarSuccess(res) {
|
|
@@ -548,7 +502,7 @@
|
|
|
.right-text-title-box{
|
|
|
font-size:14px;
|
|
|
width:300px;
|
|
|
- padding:10px 20px;
|
|
|
+ padding:10px 14px;
|
|
|
background-color: #f5f5f5;
|
|
|
border: 1px solid #E0E0E0;
|
|
|
border-radius: 4px 4px 4px 4px;
|
|
@@ -706,8 +660,7 @@
|
|
|
border:1px dashed #E0E0E0;
|
|
|
}
|
|
|
.up-img-text{
|
|
|
- line-height:40px;
|
|
|
- margin-bottom:20px;
|
|
|
+ line-height:20px;
|
|
|
font-size:14px;
|
|
|
color:#999;
|
|
|
}
|