| | |
| | | <text>其它隐患问题</text> |
| | | <text class="item-content">{{info.remark}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.rectificationNoticeFlag == 1"> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.rectificationNoticeFlag == 2"> |
| | | <text>下发整改通知</text> |
| | | <text class="item-content">是</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.punishFlag == 1"> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.punishFlag == 2"> |
| | | <text>是否处罚</text> |
| | | <text class="item-content">是</text> |
| | | </view> |
| | |
| | | <text>整改截至时间</text> |
| | | <text class="item-content">{{info.rectificationEndTime}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="inof.remark"> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.remark"> |
| | | <text>其它隐患问题</text> |
| | | <text class="item-content">{{info.remark}}</text> |
| | | </view> |
| | |
| | | <u-image :src="i" width="100rpx" height="100rpx"></u-image> |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>状态</text> |
| | | <text v-if="info.status == 1">待审核</text> |
| | | <text v-if="info.status == 2">审核成功</text> |
| | | <text v-if="info.status == 3">审核驳回</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="info.status == 3 && info.reasonFailure"> |
| | | <text>驳回原因</text> |
| | | <text class="item-content">{{info.reasonFailure}}</text> |
| | | </view> |
| | | |
| | | <view class="mt-20 bgc-ff"> |
| | | <block v-for="(item,index) in itemList"> |
| | | <block v-for="(i,k) in item.children"> |
| | |
| | | </view> |
| | | <u-collapse ref="collapse" v-if="i.id == n.itemId && n.state == 0"> |
| | | <u-collapse-item :name="index" :title="i.title" value="存在"> |
| | | <view class="mb-20" v-if="n.remark"> |
| | | <view class="f-26 mb-10" style="color:#000">隐患描述</view> |
| | | <view class="f-28" style="color:#000"> |
| | | {{n.remark}} |
| | | </view> |
| | | </view> |
| | | <view class="mb-20" v-if="n.imageUrls"> |
| | | <view class="f-26 mb-10" style="color:#000">隐患照片</view> |
| | | <view class="f-26 mb-10 c-00">隐患照片</view> |
| | | <view class="flex flex-wrap"> |
| | | <view class="mr-20" v-for="r in ($setImageUrl(n.imageUrls))"> |
| | | <u-image :src="r" width="100rpx" height="100rpx" |
| | | <u-image :src="r" width="140rpx" height="140rpx" |
| | | @click="previewImage($setImageUrl(n.imageUrls),i)"></u-image> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class=""> |
| | | <view class="f-26 mb-10">整改后照片</view> |
| | | <u-upload :fileList="form.images" :previewFullImage="uploadConfig.previewFullImage" |
| | | |
| | | <view class="mb-20" v-if="n.remark"> |
| | | <view class="f-26 mb-10 c-00">隐患描述</view> |
| | | <view class="f-28 c-00"> |
| | | {{n.remark}} |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="mb-20" v-if="roleType == 2 || (roleType == 1 && n.rectificationImageUrls)"> |
| | | <view class="f-26 mb-10 c-00">整改后照片</view> |
| | | <u-upload v-if="roleType == 2" :fileList="n.urls" |
| | | :previewFullImage="uploadConfig.previewFullImage" |
| | | :accept="uploadConfig.acceptImg" :multiple="uploadConfig.multiple" |
| | | :maxCount="uploadConfig.maxCount" :capture="uploadConfig.capture" |
| | | @afterRead="afterReadImg" @delete="deletePic"> |
| | | @afterRead="afterReadImgs($event,n,m)" @delete="deleteImages($event,m)"> |
| | | <view class="upload-item upload-icon flex_base"> |
| | | <u-icon name="/static/icon/upload.png" width="60rpx" |
| | | height="60rpx"></u-icon> |
| | | </view> |
| | | </u-upload> |
| | | |
| | | |
| | | <view class="flex flex-wrap" v-if="roleType == 1 && n.rectificationImageUrls"> |
| | | <view class="mr-20" v-for="r in ($setImageUrl(n.rectificationImageUrls))"> |
| | | <u-image :src="r" width="140rpx" height="140rpx" |
| | | @click="previewImage($setImageUrl(n.rectificationImageUrls),i)"></u-image> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="" v-if="roleType == 2 || (roleType == 1 && n.rectificationRemark)"> |
| | | <view class="f-26 mb-10 c-00">整改后描述</view> |
| | | <u-textarea v-model="n.rectificationRemark" placeholder="请输入处罚说明内容" |
| | | placeholderClass="c-99 f-26" :disabled="roleType == 1?true:false"></u-textarea> |
| | | </view> |
| | | </u-collapse-item> |
| | | </u-collapse> |
| | |
| | | </block> |
| | | </view> |
| | | |
| | | |
| | | <footer-btn /> |
| | | <view class="blank"></view> |
| | | <footer-btn @click="submitInfo" v-if="roleType == 2 && (info.status == 1 || info.status == 3)" /> |
| | | <audit-action v-if="roleType == 1 && info.status == 1" @handle="submitAudit" /> |
| | | </view> |
| | | </template> |
| | | |
| | |
| | | import uploadMixin from "@/mixin/uploadMixin"; |
| | | import { |
| | | getPlaceCheckItem, |
| | | getPlaceCheckDetail, |
| | | getPlaceCheckReformDetail |
| | | getPlaceCheckReformDetail, |
| | | addPlaceCheckReform, |
| | | auditPlaceCheckReform |
| | | } from '@/api/place/place.js' |
| | | import auditAction from '../components/actionBtn.vue' |
| | | export default { |
| | | mixins: [uploadMixin], |
| | | components: { |
| | | auditAction |
| | | }, |
| | | data() { |
| | | return { |
| | | info: {}, |
| | | images: [], |
| | | signatureUrl: [], |
| | | label: "", |
| | | itemList: [] |
| | | itemList: [], |
| | | roleType: '' //1.民警/系统管理员 2.场所负责人 |
| | | } |
| | | }, |
| | | async onLoad(option) { |
| | | let { |
| | | roleName |
| | | } = uni.getStorageSync("activeRole") |
| | | if (roleName == "居民") { |
| | | this.roleType = 2; |
| | | } |
| | | if (roleName == "民警" || roleName == "系统管理员") { |
| | | this.roleType = 1; |
| | | } |
| | | |
| | | await this.getItem(); |
| | | this.getDetail(option.id); |
| | | }, |
| | |
| | | getPlaceCheckReformDetail({ |
| | | taskId: id |
| | | }).then(res => { |
| | | this.info = res.data; |
| | | let data = res.data; |
| | | // this.info = res.data; |
| | | this.images = this.$setImageUrl(res.data.imageUrls); |
| | | this.signatureUrl = this.$setImageUrl(res.data.signaturePath); |
| | | if (res.data.placePoiLabelVOList.length) { |
| | | this.label = res.data.placePoiLabelVOList[res.data.placePoiLabelVOList.length - 1] |
| | | .labelName; |
| | | } |
| | | |
| | | // this.label = res.data. |
| | | for (let i of data.patrolRecordVOList) { |
| | | if ((data.status == 1 || data.status == 3) && this.roleType == 2) { |
| | | if (i.rectificationImageUrls) { |
| | | i.urls = this.$setImageUrl(i.rectificationImageUrls, 2); |
| | | } else { |
| | | i.urls = []; |
| | | } |
| | | } |
| | | } |
| | | this.info = data; |
| | | }) |
| | | }, |
| | | |
| | |
| | | }) |
| | | }, |
| | | |
| | | async afterReadImgs(event, item, fIndex) { |
| | | uni.showLoading({ |
| | | title: "上传中..." |
| | | }) |
| | | let children = this.info.patrolRecordVOList; |
| | | let lists = [].concat(event.file) |
| | | let fileListLen = item.urls.length; |
| | | lists.map((item) => { |
| | | children[fIndex].urls.push({ |
| | | ...item, |
| | | status: 'uploading', |
| | | message: '上传中' |
| | | }) |
| | | this.$set(this.info, "patrolRecordVOList", children) |
| | | }) |
| | | for (let i = 0; i < lists.length; i++) { |
| | | const result = await this.uploadFilePromise(lists[i].url) |
| | | children[fIndex].urls.splice(fileListLen, 1, Object.assign({}, { |
| | | url: result.data.link, |
| | | name: result.data.name |
| | | })) |
| | | this.$set(this.info, "patrolRecordVOList", children) |
| | | fileListLen++ |
| | | } |
| | | this.loadingClose() |
| | | }, |
| | | |
| | | setUrl(src) { |
| | | return this.$setImageUrl(url) |
| | | deleteImages(event, index) { |
| | | let children = this.info.patrolRecordVOList; |
| | | children[index].urls.splice(event.index, 1); |
| | | this.$set(this.info, "patrolRecordVOList", children) |
| | | }, |
| | | |
| | | setImages(key) { |
| | | if (!key) { |
| | | return "" |
| | | } else { |
| | | let urls = []; |
| | | for (let i of key) { |
| | | urls.push(i.name); |
| | | } |
| | | return urls.join(",") |
| | | } |
| | | }, |
| | | |
| | | previewImage(urls, current) { |
| | |
| | | urls, |
| | | current |
| | | }) |
| | | } |
| | | }, |
| | | |
| | | |
| | | //整改提交 |
| | | submitInfo() { |
| | | uni.showLoading({ |
| | | title: "加载中..." |
| | | }) |
| | | let data = this.info; |
| | | for (let i of data.patrolRecordVOList) { |
| | | if (i.urls) { |
| | | i.rectificationImageUrls = this.setImages(i.urls) |
| | | } |
| | | delete i.urls; |
| | | } |
| | | if (data.status == 3) { |
| | | data.status = 1; |
| | | } |
| | | |
| | | addPlaceCheckReform(data).then(res => { |
| | | uni.hideLoading() |
| | | if (res.code == 200) { |
| | | this.$showTips("操作成功", "success"); |
| | | setTimeout(() => { |
| | | uni.navigateBack() |
| | | }, 300) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | //审核 |
| | | submitAudit(val) { |
| | | uni.showLoading({ |
| | | title: "加载中..." |
| | | }) |
| | | auditPlaceCheckReform({ |
| | | id: this.info.id, |
| | | taskId: this.info.taskId, |
| | | status: val.type, |
| | | rectificationFlag: val.type == 3 ? 1 : 2, |
| | | reasonFailure: val.remark |
| | | }).then(res => { |
| | | uni.hideLoading() |
| | | if (res.code == 200) { |
| | | this.$showTips("操作成功"); |
| | | setTimeout(() => { |
| | | uni.navigateBack() |
| | | }, 300) |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | height: 140rpx; |
| | | border: 1px solid #EEEEEE; |
| | | } |
| | | |
| | | .blank { |
| | | width: 100%; |
| | | height: 140rpx; |
| | | } |
| | | |
| | | .c-00 { |
| | | color: #000; |
| | | } |
| | | </style> |