|
@@ -31,7 +31,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<!-- 待整改 -->
|
|
|
- <view v-if="rectifyStatus==0">
|
|
|
+ <view v-if="rectifyStatus==0 && item.rectifyGentle">
|
|
|
<view class="await">
|
|
|
<view class="result">
|
|
|
<view class="result_l">整改结果</view>
|
|
@@ -43,17 +43,17 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="describe">
|
|
|
- <view class="describe_l">原因描述:</view>
|
|
|
- <textarea class="describe_r" type="text" v-model="form.yhMs" maxlength="50" placeholder="请输入原因描述" placeholder-style="font-size:28rpx;color:#999;"></textarea>
|
|
|
+ <view class="describe_l">{{describeTitle}}:</view>
|
|
|
+ <textarea class="describe_r" type="text" v-model="form.rectifyDescribe" maxlength="50" placeholder="请输入描述内容" placeholder-style="font-size:28rpx;color:#999;"></textarea>
|
|
|
</view>
|
|
|
<view class="check-for-img-max-box">
|
|
|
<view class="left-title-p">隐患照片(最多上传5张):</view>
|
|
|
<view class="right-img-box">
|
|
|
- <view class="img-box" v-for="(imgUrl,imgIndex) in form.yhImg" :key="imgIndex">
|
|
|
+ <view class="img-box" v-for="(imgUrl,imgIndex) in form.imgDtoList" :key="imgIndex">
|
|
|
<img class="img-data" :src="configURL+imgUrl">
|
|
|
<img class="position-img" src="@/pages_manage/images/icon_ssp_closure.png" @click="delImg(imgIndex)">
|
|
|
</view>
|
|
|
- <img class="add-button" src="@/pages_manage/images/icon_07.png" @click="selectImage()" v-if="form.yhImg.length<5">
|
|
|
+ <img class="add-button" src="@/pages_manage/images/icon_07.png" @click="selectImage()" v-if="form.imgDtoList.length<5">
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -63,39 +63,36 @@
|
|
|
<view class="small_title">隐患整改</view>
|
|
|
<view class="grade">
|
|
|
<text>整改结果:</text>
|
|
|
- <text style="color: #0183FA;">已整改</text>
|
|
|
+ <text style="color: #0183FA;">{{item.rectifyStatus==1?'已整改':'暂无法整改'}}</text>
|
|
|
</view>
|
|
|
<view class="project">
|
|
|
<view class="project_t">整改措施:</view>
|
|
|
- <view class="project_b">隐患描述隐患描述隐患描述隐患描述隐患描述描述隐患描述隐患描述隐患描述隐患描述隐患描述隐患描述</view>
|
|
|
+ <view class="project_b">{{item.rectifyDescribe}}</view>
|
|
|
</view>
|
|
|
<view class="picture">
|
|
|
<view class="picture_t">上传照片:</view>
|
|
|
<view class="picture_b">
|
|
|
- <img src="@/images/Version3.3.3/icon_xyxc_syszc.png"/>
|
|
|
- <img src="@/images/Version3.3.3/icon_xyxc_syszc.png"/>
|
|
|
- <img src="@/images/Version3.3.3/icon_xyxc_syszc.png"/>
|
|
|
- <img src="@/images/Version3.3.3/icon_xyxc_syszc.png"/>
|
|
|
+ <img :src="item.fileUrl" v-for="(item,index) in item.zgDtoList"/>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="grade">
|
|
|
<text>整改时间:</text>
|
|
|
- <text>2023-04-0614:00</text>
|
|
|
+ <text>{{item.rectifyTime}}</text>
|
|
|
</view>
|
|
|
<view class="grade" style="border:none;">
|
|
|
<text>整改人:</text>
|
|
|
- <text >李腾</text>
|
|
|
+ <text >{{item.rectifyPeople}}</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
</scroll-view>
|
|
|
- <view v-if="pageType==0" class="bottom_btn" @click="handleClick('subBtn')">提交</view>
|
|
|
+ <view v-if="rectifyStatus==0 && item.rectifyGentle" class="bottom_btn" @click="submitForm()">提交</view>
|
|
|
</view>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import { config } from '@/api/request/config.js'
|
|
|
-import { getSelectInfoByRoom,checkClapById} from '@/api/index.js'
|
|
|
+import { getSelectInfoByRoom,checkClapById,checkClapRectify} from '@/api/index.js'
|
|
|
export default {
|
|
|
name: "rectifyList",
|
|
|
components: {
|
|
@@ -108,11 +105,13 @@ export default {
|
|
|
rectifyStatus:'',//整改状态,0是待整改,1是已整改,2是暂无法整改
|
|
|
pageType:2,
|
|
|
form:{
|
|
|
- yhMs:'',
|
|
|
- yhImg:[],
|
|
|
- opinion:'',
|
|
|
+ id:'',
|
|
|
+ rectifyStatus:1,//0待整改 1已整改 2暂无法整改
|
|
|
+ rectifyDescribe:'',
|
|
|
+ imgDtoList:[],
|
|
|
},
|
|
|
item:{},
|
|
|
+ describeTitle:'整改措施',
|
|
|
resultIndex:0,
|
|
|
resultArray:['已整改','暂无法整改'],
|
|
|
}
|
|
@@ -151,6 +150,13 @@ export default {
|
|
|
//整改结果
|
|
|
tabClick(index) {
|
|
|
this.resultIndex = index;
|
|
|
+ if(index==0){
|
|
|
+ this.describeTitle='整改措施';
|
|
|
+ this.form.rectifyStatus=1;
|
|
|
+ }else if(index==1){
|
|
|
+ this.describeTitle='原因描述';
|
|
|
+ this.form.rectifyStatus=2;
|
|
|
+ }
|
|
|
},
|
|
|
//滚动事件
|
|
|
scrollGet(){},
|
|
@@ -165,7 +171,7 @@ export default {
|
|
|
// 图片上传
|
|
|
selectImage() {
|
|
|
let self = this;
|
|
|
- if(this.form.yhImg.length>4){
|
|
|
+ if(this.form.imgDtoList.length>4){
|
|
|
uni.showToast({
|
|
|
title: '最多上传5张图片',
|
|
|
icon:"none",
|
|
@@ -201,7 +207,7 @@ export default {
|
|
|
success: (uploadFileRes) => {
|
|
|
let res = JSON.parse(uploadFileRes.data);
|
|
|
if(res.code == 200){
|
|
|
- this.form.yhImg.push(res.data.url);
|
|
|
+ this.form.imgDtoList.push({'fileUrl':res.data.url,'fileName':res.data.name});
|
|
|
console.log(res.data.url)
|
|
|
}else{
|
|
|
uni.showToast({
|
|
@@ -220,7 +226,7 @@ export default {
|
|
|
},
|
|
|
//删除图片
|
|
|
delImg(minIndex){
|
|
|
- this.form.yhImg.splice(minIndex,1);
|
|
|
+ this.form.imgDtoList.splice(minIndex,1);
|
|
|
this.$forceUpdate();
|
|
|
},
|
|
|
//随手拍详情
|
|
@@ -229,9 +235,29 @@ export default {
|
|
|
const {data} = await checkClapById({id:this.id});
|
|
|
if(data.code == 200){
|
|
|
_this.item=data.data;
|
|
|
+ _this.form.id=data.data.id;
|
|
|
|
|
|
}
|
|
|
},
|
|
|
+ //提交
|
|
|
+ async submitForm(){
|
|
|
+ let _this = this;
|
|
|
+ const {data} = await checkClapRectify(_this.form);
|
|
|
+ if(data.code == 200){
|
|
|
+ uni.showToast({
|
|
|
+ title: '提交成功',
|
|
|
+ icon:"none",
|
|
|
+ mask:true,
|
|
|
+ duration: 2000
|
|
|
+ });
|
|
|
+ uni.redirectTo({
|
|
|
+ url: '/pages/pages_safetyExamine/snapshotManage/snapshotList?pageType=2'
|
|
|
+ });
|
|
|
+
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
|
|
|
}
|
|
|
}
|