初始化

pull/2/head
guoyuepeng 2023-11-08 09:09:27 +08:00
parent 6846e446b6
commit bd5bbaefde
10 changed files with 1861 additions and 1561 deletions

View File

@ -74,7 +74,8 @@
</view>
<view class="cu-form-group" v-if="isHidden==1">
<view class="title">发现问题</view>
<button v-if="!forbidEdit" class="cu-btn round bg-blue" @click="addHidden"></button>
<button v-if="!forbidEdit && form.STATUS==0" class="cu-btn round bg-blue"
@click="addHidden">添加</button>
</view>
<view style="padding: 20upx" v-if="form.hiddenList">
<uni-table border stripe emptyText="暂无更多数据" v-if="isHidden==1">
@ -90,7 +91,8 @@
<uni-td>{{ item.HIDDENDESCR }}</uni-td>
<uni-td style="text-align: center;">
<icon type="info" size="26" style="margin-right: 8px" @tap="showHidden(item, index)" />
<icon type="cancel" size="26" @tap="removeHidden(item, index)" v-if="!forbidEdit" />
<icon type="cancel" size="26" @tap="removeHidden(item, index)"
v-if="!forbidEdit && form.STATUS==0" />
</uni-td>
</uni-tr>
</uni-table>
@ -111,7 +113,8 @@
<scroll-view scroll-x class="bg-white nav" scroll-with-animation>
<view class="cu-item">
<view>
<image :src=" baseImgPath +form.IMG_PATH" @click="ViewShowImage" style="width: 200upx;height: 150upx"></image>
<image :src=" baseImgPath +form.IMG_PATH" @click="ViewShowImage"
style="width: 200upx;height: 150upx"></image>
</view>
</view>
</scroll-view>
@ -125,8 +128,7 @@
<view class="de-sub-content">
<view class="de-sub-content" style="background-color: #000;width: 120upx;">
<image src="/static/icon-apps/video.png" mode="aspectFill" @click="playVideo"
:data-src="baseImgPath +form.VIDEO_PATH"
style="width: 120upx;height: 120upx;"></image>
:data-src="baseImgPath +form.VIDEO_PATH" style="width: 120upx;height: 120upx;"></image>
</view>
</view>
</view>
@ -136,8 +138,10 @@
</view>
<view class="cu-bar btn-group" style="margin-top: 30upx;">
<button v-if="!forbidEdit && form.STATUS==0" class="cu-btn bg-blue margin-tb-sm lg" @click="$noMultipleClicks(goSubmit,'1')"></button>
<button v-if="forbidEdit" class="cu-btn bg-green margin-tb-sm lg" @click="$noMultipleClicks(goback)"></button>
<button v-if="!forbidEdit && form.STATUS==0" class="cu-btn bg-blue margin-tb-sm lg"
@click="$noMultipleClicks(goSubmit,'1')">提交</button>
<button v-if="forbidEdit" class="cu-btn bg-green margin-tb-sm lg"
@click="$noMultipleClicks(goback)">返回</button>
</view>
<view class="padding flex flex-direction"></view>
@ -149,39 +153,36 @@
隐患照片
</view>
</view>
<view class="cu-form-group" v-if="hiddenForm.hiddenImgs.length>0">
<view class="cu-form-group" v-if="hiddenForm.hiddenVideos.length>0">
<view class="grid col-4 grid-square flex-sub">
<view class="bg-img" v-for="(item,index) in hiddenForm.hiddenImgs" :key="index" @tap="ViewImage" :data-id="item.IMGFILES_ID" data-type="0" :data-url="hiddenForm.hiddenImgs[index].FILEPATH">
<image v-if="item.IMGFILES_ID" :src="baseImgPath + hiddenForm.hiddenImgs[index].FILEPATH" mode="aspectFill"></image>
<view class="bg-img" v-for="(item,index) in hiddenForm.hiddenVideos" :key="index"
@tap="ViewImage" :data-id="item.IMGFILES_ID" data-type="0"
:data-url="hiddenForm.hiddenImgs[index].FILEPATH">
<image v-if="item.IMGFILES_ID"
:src="baseImgPath + hiddenForm.hiddenImgs[index].FILEPATH" mode="aspectFill">
</image>
<image v-else :src="hiddenForm.hiddenImgs[index].FILEPATH" mode="aspectFill"></image>
</view>
</view>
</view>
<!-- <view class="cu-bar bg-white">-->
<!-- <view class="action">-->
<!-- 隐患视频-->
<!-- </view>-->
<!-- <view class="action">-->
<!-- {{hiddenForm.hiddenVideos.length}}/1-->
<!-- </view>-->
<!-- </view>-->
<!-- <view class="cu-form-group">-->
<!-- <view class="grid col-4 grid-square flex-sub">-->
<!-- <view class="bg-img" v-for="(item,vindex) in hiddenForm.hiddenVideos" :key="vindex" @tap="ViewVideo" data-type="0" :data-url="hiddenForm.hiddenVideos[vindex].FILEPATH" style="background-color: #000">-->
<!-- <image src="/static/icon-apps/video.png" mode="aspectFill" @click="playVideo"-->
<!-- :data-src="hiddenForm.hiddenVideos[vindex].FILEPATH"></image>-->
<!-- <view class="cu-tag bg-red" @tap.stop="DelVideo" data-type="0" :data-index="vindex" v-if="!forbidEdit">-->
<!-- <text class='cuIcon-close'></text>-->
<!-- </view>-->
<!-- </view>-->
<!-- <view class="solids" @tap="chooseVideo(0)" v-if="hiddenForm.hiddenVideos.length == 0 && !forbidEdit">-->
<!-- <text class='cuIcon-cameraadd'></text>-->
<!-- </view>-->
<!-- </view>-->
<!-- </view>-->
<view class="cu-bar bg-white" v-if="hiddenForm.hiddenVideos.length>0">
<view class="action">
隐患视频
</view>
</view>
<view class="cu-form-group" v-if="hiddenForm.hiddenVideos.length>0">
<view class="grid col-4 grid-square flex-sub">
<view class="bg-img" v-for="(item,vindex) in hiddenForm.hiddenVideos" :key="vindex"
style="background-color: #000">
<image src="/static/icon-apps/video.png" mode="aspectFill" @click="playVideo"
:data-src="baseImgPath +hiddenForm.hiddenVideos[vindex].FILEPATH"></image>
</view>
</view>
</view>
<view class="cu-form-textarea">
<view class="cu-form-title text-hui">隐患描述</view>
<textarea maxlength="-1" :disabled="forbidEdit" v-model="hiddenForm.HIDDENDESCR" placeholder="请对隐患进行详细描述(必填项)"></textarea>
<textarea maxlength="-1" :disabled="forbidEdit" v-model="hiddenForm.HIDDENDESCR"
placeholder="请对隐患进行详细描述(必填项)"></textarea>
</view>
<view class="cu-form-group">
<view class="title">隐患部位</view>
@ -193,61 +194,39 @@
<view class="cu-form-group">
<view class="title">隐患级别</view>
<view class="picker-tree-box">
<view class="picker-tree" @tap="forbidEdit ? null : showZgTree('tkiTree4', 4)">{{hiddenForm.HIDDENLEVEL_NAME || '请选择'}}</view>
<view class="picker-tree" @tap="forbidEdit ? null : showZgTree('tkiTree4', 4)">
{{hiddenForm.HIDDENLEVEL_NAME || '请选择'}}</view>
</view>
<tki-tree ref="tkiTree4" :selectParent=false :range="hiddenLevelTreeList" rangeKey="name" @confirm="zgtreeConfirm($event,'hiddenLevelTreeList')"
@cancel="zgtreeCancel"></tki-tree>
<tki-tree ref="tkiTree4" :selectParent=false :range="hiddenLevelTreeList" rangeKey="name"
@confirm="zgtreeConfirm($event,'hiddenLevelTreeList')" @cancel="zgtreeCancel"></tki-tree>
</view>
<view class="cu-form-group">
<view class="title">隐患类型</view>
<view class="picker-tree-box">
<view class="picker-tree" @tap="forbidEdit ? null : showZgTree('tkiTree5', 5)">{{hiddenForm.HIDDENTYPE_NAME || '请选择'}}</view>
<view class="picker-tree" @tap="forbidEdit ? null : showZgTree('tkiTree5', 5)">
{{hiddenForm.HIDDENTYPE_NAME || '请选择'}}</view>
</view>
<tki-tree ref="tkiTree5" :selectParent=false :range="hiddenTypeTreeList" rangeKey="name" @confirm="zgtreeConfirm($event,'hiddenTypeTreeList')"
@cancel="zgtreeCancel">
<tki-tree ref="tkiTree5" :selectParent=false :range="hiddenTypeTreeList" rangeKey="name"
@confirm="zgtreeConfirm($event,'hiddenTypeTreeList')" @cancel="zgtreeCancel">
</tki-tree>
</view>
<view class="cu-form-group">
<view class="title">隐患处置</view>
<radio-group @change="changeRadioGroup1($event)">
<!-- <label class="radio"><radio value="1" :checked="hiddenForm.RECTIFICATIONTYPE === '1'" />立即整改</label>-->
<label class="radio"><radio value="2" :checked="hiddenForm.RECTIFICATIONTYPE === '2'" />限期整改</label>
<label class="radio">
<radio value="2" :checked="hiddenForm.RECTIFICATIONTYPE === '2'" />限期整改
</label>
</radio-group>
</view>
<view class="cu-form-group" v-if="hiddenForm.RECTIFICATIONTYPE === '2'">
<view class="title">整改期限</view>
<ruiDatePicker :start="todayDate" fields="minute" :value="hiddenForm.RECTIFICATIONDEADLINE || '请选择'"
@change="changeDiscoverDate" v-if="!forbidEdit"></ruiDatePicker>
<ruiDatePicker :start="todayDate" fields="minute"
:value="hiddenForm.RECTIFICATIONDEADLINE || '请选择'" @change="changeDiscoverDate"
v-if="!forbidEdit"></ruiDatePicker>
<view v-else>{{hiddenForm.RECTIFICATIONDEADLINE}}</view>
</view>
<!-- <view class="cu-bar bg-white" v-if="hiddenForm.RECTIFICATIONTYPE === '1'">-->
<!-- <view class="action">-->
<!-- 隐患照片-->
<!-- </view>-->
<!-- <view class="action">-->
<!-- {{hiddenForm.zgImgs.length}}/4-->
<!-- </view>-->
<!-- </view>-->
<!-- <view class="cu-form-group" v-if="hiddenForm.RECTIFICATIONTYPE === '1'">-->
<!-- <view class="grid col-4 grid-square flex-sub">-->
<!-- <view class="bg-img" v-for="(item,index) in hiddenForm.zgImgs" :key="index" @tap="ViewImage1" :data-id="item.IMGFILES_ID" data-type="0" :data-url="hiddenForm.zgImgs[index].FILEPATH">-->
<!-- <image v-if="item.IMGFILES_ID" :src="baseImgPath + hiddenForm.zgImgs[index].FILEPATH" mode="aspectFill"></image>-->
<!-- <image v-else :src="hiddenForm.zgImgs[index].FILEPATH" mode="aspectFill"></image>-->
<!-- <view class="cu-tag bg-red" @tap.stop="DelImg1" data-type="0" :data-index="index">-->
<!-- <text class='cuIcon-close'></text>-->
<!-- </view>-->
<!-- </view>-->
<!-- <view class="solids" @tap="ChooseImage1(0)" v-if="hiddenForm.zgImgs.length<4">-->
<!-- <text class='cuIcon-cameraadd'></text>-->
<!-- </view>-->
<!-- </view>-->
<!-- </view>-->
<!-- <view class="cu-form-textarea" v-if="hiddenForm.RECTIFICATIONTYPE === '1'">-->
<!-- <view class="cu-form-title text-hui">整改描述</view>-->
<!-- <textarea maxlength="-1" :disabled="modalName!=null" v-model="hiddenForm.RECTIFYDESCR" placeholder="请输入整改描述(必填项)"></textarea>-->
<!-- </view>-->
<view class="cu-form-group">
<view class="title" style="height: auto;">
<view>整改部门</view>
@ -258,21 +237,22 @@
{{ hiddenForm.RECTIFICATIONDEPT_NAME || '请选择' }}
</view>
</view>
<tki-tree ref="tkiTree6" :selectParent=true :range="treeNode" rangeKey="UNITS_NAME" @confirm="zgtreeConfirm($event,'rectificationSiteuserColumns')"
@cancel="zgtreeCancel"></tki-tree>
<tki-tree ref="tkiTree6" :selectParent=true :range="treeNode" rangeKey="UNITS_NAME"
@confirm="zgtreeConfirm($event,'rectificationSiteuserColumns')" @cancel="zgtreeCancel">
</tki-tree>
</block>
<block v-else>{{ hiddenForm.RECTIFICATIONDEPT_NAME }}</block>
</view>
<view class="cu-form-group" v-if="hiddenForm.RECTIFICATIONDEPT_NAME">
<view class="title">整改人</view>
<picker @change="rectificationSiteuserConfirmPicker" :disabled="forbidEdit" :value="hiddenForm.RECTIFICATIONOR_INDEX"
:range="rectificationSiteuserColumns" range-key="NAME">
<picker @change="rectificationSiteuserConfirmPicker" :disabled="forbidEdit"
:value="hiddenForm.RECTIFICATIONOR_INDEX" :range="rectificationSiteuserColumns"
range-key="NAME">
<view class="picker">
{{ hiddenForm.RECTIFICATIONOR_NAME || '请选择' }}
</view>
</picker>
</view>
<view class="de-drawer-bottom">
<view class="cz-btn">
<text class="cu-btn" @click="cancelHidden"></text>
@ -308,7 +288,14 @@
<script>
import {
basePath,corpinfoId,deptId,loginUser,formatDate,loginSession,baseImgPath,loginUserId
basePath,
corpinfoId,
deptId,
loginUser,
formatDate,
loginSession,
baseImgPath,
loginUserId
} from '@/common/tool.js';
import tkiTree from "@/components/select-tree/select-tree.vue"
import sign from '@/components/sign/sign.vue';
@ -319,7 +306,11 @@
export default {
components: {
tkiTree, ruiDatePicker, sign, moreSelect, uniPopup
tkiTree,
ruiDatePicker,
sign,
moreSelect,
uniPopup
},
data() {
return {
@ -351,7 +342,10 @@
VIDEOMANAGER_ID: "",
VIDEOMANAGER_NAME: "",
WARNING_TIME: "",
hiddenList: [{ ...this.hiddenForm }], //
VIDEO_PATH: "",
hiddenList: [{
...this.hiddenForm
}], //
}, //
hiddenIds: [], // ID
delSituations: [], //
@ -401,13 +395,30 @@
},
modalShow: false,
videoSrc: '',
hiddenRules:[
{name:'HIDDENDESCR',message:'输入隐患描述'},
{name:'HIDDENPART',message:'请选择隐患部位'},
{name:'HIDDENLEVEL',message:'请选择隐患级别'},
{name:'HIDDENTYPE',message:'请选择隐患类型'},
{name:'RECTIFICATIONDEPT',message:'请选择整改部门'},
{name:'RECTIFICATIONOR',message:'请选择整改人'}
hiddenRules: [{
name: 'HIDDENDESCR',
message: '输入隐患描述'
},
{
name: 'HIDDENPART',
message: '请选择隐患部位'
},
{
name: 'HIDDENLEVEL',
message: '请选择隐患级别'
},
{
name: 'HIDDENTYPE',
message: '请选择隐患类型'
},
{
name: 'RECTIFICATIONDEPT',
message: '请选择整改部门'
},
{
name: 'RECTIFICATIONOR',
message: '请选择整改人'
}
],
todayDate: '',
modalName: null,
@ -461,7 +472,7 @@
if (res.data.pd.ISTRUE) {
_this.isReally = res.data.pd.ISTRUE
}
if(res.data.pd.hiddenList.length>0){
if (res.data.pd.hiddenList) {
_this.isHidden = 1
}
if (res.data.pd.STATUS == 1) {
@ -496,7 +507,8 @@
}
}
//
var hiddenList = [], fileList = [];
var hiddenList = [],
fileList = [];
if (this.form.hiddenList.length > 0) {
for (let i = 0; i < this.form.hiddenList.length; i++) {
fileList = []
@ -698,14 +710,11 @@
this.form.inspectorList[index].INSPECTION_USER_ID = this.inspectorList[index][e.detail.value].USER_ID;
this.form.inspectorList[index].INSPECTION_USER_NAME = this.inspectorList[index][e.detail.value].NAME;
},
addSituation() {
this.form.situationList.push(
{
this.form.situationList.push({
INSPECTION_SITUATION_ID: '',
SITUATION: ''
}
)
})
},
removeSituation(item, index) {
var _this = this;
@ -726,16 +735,14 @@
},
addInspector() {
this.form.inspectorList.push(
{
this.form.inspectorList.push({
INSPECTION_INSPECTOR_ID: '', //
INSPECTION_DEPARTMENT_ID: '', //ID
INSPECTION_DEPARTMENT_NAME: '',
INSPECTION_USER_ID: '', //ID
INSPECTION_USER_INDEX: '',
INSPECTION_USER_NAME: ''
}
)
})
},
removeInspector(item, index) {
var _this = this;
@ -776,16 +783,27 @@
//
addHidden() {
this.resetHd()
console.log('打开隐患添加窗口')
// this.creatorList = [{NAME: loginUser.NAME, USER_ID: loginUser.USER_ID}]
this.$refs['showHiddenWindow'].open()
this.hiddenForm.RECTIFICATIONDEPT = this.form.RECTIFICATIONDEPT
this.hiddenForm.RECTIFICATIONDEPT_NAME = this.form.RECTIFICATIONDEPT_NAME
this.hiddenForm.RECTIFICATIONOR = this.form.RECTIFICATIONOR
this.hiddenForm.RECTIFICATIONOR_NAME = this.form.RECTIFICATIONOR_NAME
this.getUserList('rectificationSiteuserColumns',this.form.RECTIFICATIONDEPT)
this.$forceUpdate()
this.showHiddenWindow = true
this.hiddenIsEdit = true
},
//
showHidden(item) {
this.resetHd()
this.creatorList = [{NAME: loginUser.NAME, USER_ID: loginUser.USER_ID}]
this.creatorList = [{
NAME: loginUser.NAME,
USER_ID: loginUser.USER_ID
}]
this.hiddenForm = item
this.$refs['showHiddenWindow'].open()
this.showHiddenWindow = true
@ -828,8 +846,12 @@
return;
}
}
this.hiddenRules.map(({name,message}) => {
if (!this.hiddenForm[name] || this.hiddenForm[name] === '请选择' || this.hiddenForm[name] === '请输入' ) {
this.hiddenRules.map(({
name,
message
}) => {
if (!this.hiddenForm[name] || this.hiddenForm[name] === '请选择' || this.hiddenForm[name] ===
'请输入') {
uni.showToast({
icon: 'none',
title: message,
@ -845,7 +867,7 @@
title: '请稍候'
})
this.hiddenForm.IMG_PATH = this.form.IMG_PATH
this.hiddenForm.REMARKS = this.form.REMARKS
this.hiddenForm.REMARKS = this.form.VIDEO_PATH
if (this.hiddenForm.RECTIFICATIONTYPE === '1') {
this.hiddenForm.RECTIFICATIONDEADLINE = ''
}
@ -878,7 +900,8 @@
}
uni.previewImage({
urls: files,
current: e.currentTarget.dataset.id ? this.baseImgPath + e.currentTarget.dataset.url : e.currentTarget.dataset.url
current: e.currentTarget.dataset.id ? this.baseImgPath + e.currentTarget.dataset.url : e
.currentTarget.dataset.url
});
} else {
let files = [];
@ -902,7 +925,8 @@
}
uni.previewImage({
urls: files,
current: e.currentTarget.dataset.id ? this.baseImgPath + e.currentTarget.dataset.url : e.currentTarget.dataset.url
current: e.currentTarget.dataset.id ? this.baseImgPath + e.currentTarget.dataset.url : e
.currentTarget.dataset.url
});
},
ViewSignImage(e) {
@ -1182,7 +1206,11 @@
'Content-type': 'application/x-www-form-urlencoded'
},
url: basePath + '/app/keyProjects/listAllPersonnel',
data: {UNITS_ID:dept, NOMAIN:'1', tm:new Date().getTime()},
data: {
UNITS_ID: dept,
NOMAIN: '1',
tm: new Date().getTime()
},
success: function(res) {
if ("success" == res.data.result) {
_this[list] = res.data.varList;
@ -1206,7 +1234,9 @@
'Content-type': 'application/x-www-form-urlencoded'
},
url: basePath + '/dictionaries/listSelectTreeByTkiTree?tm=' + new Date().getTime(),
data: {DICTIONARIES_ID: '60e6481d96e44a5390ff5c347c4d1ffe'},
data: {
DICTIONARIES_ID: '60e6481d96e44a5390ff5c347c4d1ffe'
},
success: function(res) {
_this.inspectionTypeTreeList = eval(res.data.zTreeNodes);
}
@ -1243,12 +1273,15 @@
'Content-type': 'application/x-www-form-urlencoded'
},
url: basePath + '/dictionaries/listSelectTreeByTkiTree?tm=' + new Date().getTime(),
data: {DICTIONARIES_ID: '5e7cf8620ba54ad89719d0be62133c7a'},
data: {
DICTIONARIES_ID: '5e7cf8620ba54ad89719d0be62133c7a'
},
success: function(res) {
var data = JSON.parse(res.data.zTreeNodes);
for (let i = 0; i < data.length; i++) {
for (let j = 0; j < data[i].children.length; j++) {
if(data[i].children[j].id =='jdyh001' || data[i].children[j].id =='hiddenLevel1001'){
if (data[i].children[j].id == 'jdyh001' || data[i].children[j].id ==
'hiddenLevel1001') {
data[i].children.splice(j, 1)
}
}
@ -1267,7 +1300,9 @@
'Content-type': 'application/x-www-form-urlencoded'
},
url: basePath + '/dictionaries/listSelectTreeByTkiTree?tm=' + new Date().getTime(),
data: {DICTIONARIES_ID: '3babc15144444bdc8d763d0af2bdfff6'},
data: {
DICTIONARIES_ID: '3babc15144444bdc8d763d0af2bdfff6'
},
success: function(res) {
var jons = res.data.zTreeNodes;
_this.hiddenTypeTreeList = JSON.parse(jons);
@ -1281,7 +1316,9 @@
'Content-type': 'application/x-www-form-urlencoded'
},
url: basePath + '/dictionaries/listSelectTreeByTkiTree?tm=' + new Date().getTime(),
data: {DICTIONARIES_ID: '18c0a9aea6e54feab9f4ab3f46e0bc86'},
data: {
DICTIONARIES_ID: '18c0a9aea6e54feab9f4ab3f46e0bc86'
},
success: function(res) {
var jons = res.data.zTreeNodes;
_this.hiddenType2TreeList = JSON.parse(jons);
@ -1293,7 +1330,9 @@
var pages = getCurrentPages(); //
var prePage = pages[pages.length - 2]; //
prePage.$vm.initflag = true; // A init true
uni.navigateBack({delta: 1});
uni.navigateBack({
delta: 1
});
uni.hideLoading();
},
@ -1391,20 +1430,25 @@
display: flex;
text-align: left;
}
.modal_left {
flex-basis: 50%;
padding: 50upx 20upx;
border-right: 1px solid #000000;
}
.modal_right {
flex-basis: 50%;
padding: 50upx;
}
.modal_left_title,.modal_right_title{
.modal_left_title,
.modal_right_title {
font-size: 16px;
color: #000000;
font-weight: 700;
}
.checkbox-item {
display: flex;
align-items: center;
@ -1413,26 +1457,32 @@
background-color: #ffffff;
border-bottom: 1upx solid #ddd;
}
.checkbox-item:last-child {
border-bottom: none;
}
.showHiddenWindowActive {
overflow: hidden;
height: 100vh;
}
.selected {
display: flex;
align-items: center;
height: 100upx;
}
.selected .radio {
transform: scale(0.8);
margin-right: 10upx;
}
.group {
display: flex;
align-items: center;
}
.cu-form-group .title {
font-size: 28upx;
color: #666;

View File

@ -59,7 +59,7 @@
@click="$noMultipleClicks(goToDetail,item.HIDDEN_ID)">
{{(TabCur + 1) == '1' ? '验收' : '查看'}}
</button>
<button style="margin-left: 20upx;"
<!-- <button style="margin-left: 20upx;"
v-if="item.ISPUNISH !== '2'
&& !item.KEYPROJECTPUNISH_ID
&& item.PUNISH_THE_PERSON.includes(loginUserId)
@ -67,7 +67,7 @@
class="cu-btn bg-red margin-tb-sm sm"
@click.stop="fnModalShow(item)">
处罚
</button>
</button> -->
<!-- && item.CREATOR == loginUserId" -->
</text>
</view>

View File

@ -76,16 +76,16 @@
<view class="title">整改人</view>
<view>{{ hiddenForm.RECTIFICATIONOR_NAME }}</view>
</view>
<view class="cu-form-group">
<view class="cu-form-group" v-show="hiddenForm.STATE==='2'||hiddenForm.STATE==='4'">
<view class="title">整改时间</view>
<view>{{ hiddenForm.RECTIFICATIONTIME }}</view>
</view>
<view class="cu-bar bg-white">
<view class="cu-bar bg-white" v-show="hiddenForm.STATE==='2'||hiddenForm.STATE==='4'">
<view class="action">
整改照片
</view>
</view>
<view class="cu-form-group">
<view class="cu-form-group" v-show="hiddenForm.STATE==='2'||hiddenForm.STATE==='4'">
<view class="grid col-4 grid-square flex-sub">
<view class="bg-img" v-for="(item,index) in hiddenForm.zgImgs" :key="index" @tap="ViewImage1"
:data-id="item.IMGFILES_ID" data-type="0" :data-url="hiddenForm.zgImgs[index].FILEPATH">
@ -93,13 +93,13 @@
</view>
</view>
</view>
<view class="cu-form-group">
<view class="cu-form-group" v-show="hiddenForm.STATE==='4'||TabCur==='1'">
<view class="title">验收时间</view>
<ruiDatePicker v-if="TabCur == 1" :start="todayDate" fields="minute" :value="CHECKTIME || '请选择'"
@change="changeDiscoverDate"></ruiDatePicker>
<view v-else>{{hiddenForm.CHECKTIME}}</view>
</view>
<view class="cu-bar bg-white">
<view class="cu-bar bg-white" v-show="hiddenForm.STATE==='4'||TabCur==='1'">
<view class="action">
验收照片
</view>
@ -107,7 +107,7 @@
{{hiddenForm.ysImgs.length}}/4
</view>
</view>
<view class="cu-form-group">
<view class="cu-form-group" v-show="hiddenForm.STATE==='4'||TabCur==='1'">
<view class="grid col-4 grid-square flex-sub">
<view class="bg-img" v-for="(item,index) in hiddenForm.ysImgs" :key="index" @tap="ViewImage2" :data-id="item.IMGFILES_ID" data-type="0" :data-url="hiddenForm.ysImgs[index].FILEPATH">
<image v-if="item.IMGFILES_ID" :src="baseImgPath + hiddenForm.ysImgs[index].FILEPATH" mode="aspectFill"></image>
@ -121,13 +121,61 @@
</view>
</view>
</view>
<!-- <view class="cu-form-group">
<view class="title">是否进行罚款</view>
<radio-group @change="changeRadioGroup($event)">
<label class="radio"><radio value="1" :checked="hiddenForm.ISPUNISH === '1'" :disabled="TabCur == 2" /></label>
<label class="radio"><radio value="2" :checked="hiddenForm.ISPUNISH === '2'" :disabled="TabCur == 2" /></label>
</radio-group>
</view> -->
</view>
<view v-if="punishForm">
<view class="dy-list-item p20">
<view class="dy-title-flex align-center">
<text>处罚信息</text>
</view>
</view>
<view class="cu-form-group">
<view class="title">处罚原因</view>
<view>{{ punishForm.REASON }}</view>
</view>
<view class="cu-form-group">
<view class="title">处罚金额</view>
<view>{{ punishForm.AMOUT }}</view>
</view>
<view class="cu-form-group">
<view class="title">被处罚单位</view>
<view>{{ punishForm.UNITS_NAME }}</view>
</view>
<view class="cu-form-group">
<view class="title">被处罚人</view>
<view>{{ punishForm.PERSON_NAME }}</view>
</view>
<view class="cu-form-group">
<view class="title">下发人</view>
<view>{{ punishForm.CREATOR_NAME }}</view>
</view>
<view class="cu-form-group">
<view class="title">下发处罚时间</view>
<view>{{ punishForm.DATE }}</view>
</view>
<view class="cu-bar bg-white" v-if="punishForm.HANDLE_IMG">
<view class="action">
罚款缴纳单
</view>
</view>
<view class="cu-form-group" v-if="punishForm.HANDLE_IMG">
<view class="grid col-4 grid-square flex-sub">
<view class="bg-img">
<image :src="baseImgPath + punishForm.HANDLE_IMG" mode="aspectFill"></image>
</view>
</view>
</view>
<view class="cu-form-group">
<view class="title">是否缴纳罚款</view>
<view>{{punishForm.HANDLED === '1' ? '已缴' : '未缴' }}</view>
</view>
<view class="cu-form-group" v-if="punishForm.HANDLED === '1'">
<view class="title">处罚处理人</view>
<view >{{punishForm.PERSON_NAME}}</view>
</view>
<view class="cu-form-group" v-if="punishForm.HANDLED === '1'">
<view class="title" >处罚处理时间</view>
<view >{{punishForm.HANLDE_TIME}}</view>
</view>
</view>
</view>
<view class="cu-bar btn-group" style="margin-top: 30upx;">
@ -175,6 +223,7 @@ export default {
ysImgs:[],
CHECKTIME :formatDate(new Date(), 'yyyy-MM-dd hh:mm')
},
punishForm:{},
videoSrc:'',
modalShow:false,
todayDate:formatDate(new Date(), 'yyyy-MM-dd hh:mm'),
@ -207,6 +256,11 @@ export default {
uni.hideLoading();//
if (res.data != null) {
this.hiddenForm = res.data.pd
if(res.data.pd.punishForm){
this.punishForm = res.data.pd.punishForm
}else{
this.punishForm = null;
}
}
}
})
@ -293,6 +347,17 @@ export default {
}
});
},
fnImagePreview(list, index) {
const urls = [];
for (let i = 0; i < list.length; i++) {
urls.push(list[i].url);
}
const current = urls[index];
uni.previewImage({
urls,
current
})
},
changeRadioGroup(e){
if(this.TabCur == 2) return
this.hiddenForm.ISPUNISH = e.detail.value
@ -306,13 +371,13 @@ export default {
})
return
}
if(this.hiddenForm.ysImgs.length === 0){
uni.showToast({
title: `请上传验收图片`,
icon: 'none'
})
return
}
//if(this.hiddenForm.ysImgs.length === 0){
// uni.showToast({
// title: ``,
// icon: 'none'
// })
// return
//}
// if(!this.hiddenForm.ISPUNISH){
// uni.showToast({
// title: ``,
@ -384,5 +449,8 @@ export default {
</script>
<style scoped>
.dy-title-flex{
font-weight: bold;
font-size: 35upx;
}
</style>

View File

@ -24,6 +24,16 @@
@click="$noMultipleClicks(goToDetail,item)" class="dy-list-item p20">
<view class="dy-title-flex align-center">
<text>{{item.OUTSOURCED_NAME}}</text>
<text>
<view v-if="item.co>0" style="border-radius: 96px;
font-size: 10px;
padding: 0px 10px;
height: 13px;
color: #ffffff;
background-color:#dd514c ;">
{{item.co}}
</view>
</text>
</view>
<view v-show="item.IS_CORP_TYPE== '1'" class="dy-subtitle-flex">
<text>
@ -32,7 +42,7 @@
</view>
<view v-show="item.IS_CORP_TYPE== '1'" class="dy-subtitle-flex">
<text>
监督部门{{ item.Q_DEPARTMENT_NAME }}
监督部门{{ item.DEPARTMENT_NAME }}
</text>
</view>
<view v-show="item.IS_CORP_TYPE== '0'" class="dy-subtitle-flex">
@ -46,7 +56,7 @@
</text>
</view>
<view class="dy-subtitle-flex">
<text>相关方单位负责人{{item.UNITS_PIC}}</text>
<text>相关方单位负责人{{item.UNITS_PIC_NAME}}</text>
<text>电话{{item.UNITS_PHONE}}</text>
</view>
<view class="dy-subtitle-flex" style="height: 34upx;">

View File

@ -32,7 +32,7 @@
<navigator class="apps-item" hover-class="none" url="/pages/application/key-project-management/penalty-management/list">
<view class="imgs action">
<image src="../../../../static/icon-apps/icon-yxkj-1.png" mode=""></image>
<!-- <view v-if="count.HIDDEN_COUNT" class="cu-tag badge">{{count.HIDDEN_COUNT}}</view>-->
<view v-if="count.HIDDEN_COUNT" class="cu-tag badge">{{count.HIDDEN_COUNT}}</view>
</view>
<view class="text-semi" style="text-align: center;">
<view>处罚管理</view>

View File

@ -19,24 +19,31 @@
<view class="dy-list">
<view v-for="(item,index) of list" :key="index" :data-id="item.INSPECTION_ID" @click="$noMultipleClicks(goToDetail,item.KEYPROJECTPUNISH_ID)" class="dy-list-item p20">
<view class="dy-title-flex align-center">
<text>{{item.OUTSOURCED_NAME}}</text>
<text>{{item.HIDDENDESCR}}</text>
</view>
<view class="dy-subtitle-flex">
<text>被处罚单位{{ item.UNITS_NAME }}</text>
<text>被处罚人{{ item.PERSON_NAME }}</text>
<text v-show="item.ISPUNISH==='1'&&item.HANDLED==='0'">{{ item.PERSON_NAME }}</text>
</view>
<view class="dy-subtitle-flex">
<view v-show="item.ISPUNISH==='1'" class="dy-subtitle-flex">
<text>
处罚原因{{ item.REASON }}
</text>
</view>
<view class="dy-subtitle-flex">
<view v-show="item.ISPUNISH" class="dy-subtitle-flex">
<text>下发人{{ item.CREATOR_NAME }}</text>
<text>是否处罚{{ item.ISPUNISH == "2" ? "否":"是" }}</text>
</view>
<view class="dy-subtitle-flex" style="height: 34upx;">
<text>处罚处理状态{{ (TabCur + 1) == "1" ? "待处理" : "已处理" }}</text>
<text>处罚处理状态{{ item.ISPUNISH == "2" ? "不处罚":item.HANDLED == "1" ?"已完成":item.ISPUNISH == "1" ? "待反馈" : "待处罚" }}</text>
<text>
<button class="cu-btn bg-blue margin-tb-sm sm" @click="$noMultipleClicks(goToDetail,item.KEYPROJECTPUNISH_ID)"></button>
<button
v-if="!item.ISPUNISH"
class="cu-btn bg-red margin-tb-sm sm"
@click.stop="fnModalShow(item)">
处罚
</button>
<button style="margin-left: 20upx;" class="cu-btn bg-blue margin-tb-sm sm" @click="$noMultipleClicks(goToDetail,item.HIDDEN_ID)"></button>
</text>
</view>
</view>
@ -52,6 +59,57 @@
</view>
<view class="cu-tabbar-height"></view>
</scroll-view>
<view :class="['cu-modal',{'show':modalShow}]" v-if="modalShow">
<view class="cu-dialog">
<view class="cu-bar bg-white justify-end">
<view class="content">处罚</view>
<view class="action" @tap="modalShow = false">
<text class="cuIcon-close text-red"></text>
</view>
</view>
<view class="wui-form-list">
<view class="cu-form-group">
<view class="title">是否进行罚款</view>
<radio-group @change="changeRadioGroup($event)">
<label class="radio"><radio value="1" :checked="punishForm.ISPUNISH === '1'" /></label>
<label class="radio"><radio value="2" :checked="punishForm.ISPUNISH === '2'" /></label>
</radio-group>
</view>
<view v-if="punishForm.ISPUNISH==1">
<view class="cu-form-group">
<view class="title">处罚原因</view>
<input v-model="punishForm.REASON" placeholder="请输入处罚原因"></input>
</view>
<view class="cu-form-group">
<view class="title">处罚金额()</view>
<input type="number" v-model="punishForm.AMOUT" placeholder="请输入处罚金额" @blur="checkNumber"></input>
</view>
<view class="cu-form-group">
<view class="title">被处罚单位</view>
<input disabled v-model="punishForm.RECTIFICATIONDEPT_NAME" placeholder="请输入被处罚单位"></input>
</view>
<view class="cu-form-group">
<view class="title">被处罚人</view>
<input disabled v-model="punishForm.RECTIFICATIONOR_NAME" placeholder="请输入被处罚人"></input>
</view>
<view class="cu-form-group">
<view class="title">下发处罚时间</view>
<ruiDatePicker fields="minute" :value="punishForm.DATE || '请选择'" @change="changeStartDate">
</ruiDatePicker>
</view>
</view>
</view>
<view class="cu-bar bg-white justify-between">
<view class="action" style="flex-basis: 100%">
<button class="cu-btn" style="flex-basis: 50%" @click="modalShow = false">关闭</button>
<button class="cu-btn line-green text-green" style="flex-basis: 50%"
@click="fnSubmit">确认</button>
</view>
</view>
</view>
</view>
</view>
</template>
@ -84,6 +142,16 @@ export default {
TabCur: 0,
scrollLeft: 0,
tabNav: ['待反馈处罚', '已完成处罚'],
modalShow: false,
punishForm: {
HIDDEN_ID: '',
ISPUNISH: '',
RECTIFICATIONDEPT_NAME: '',
RECTIFICATIONOR_NAME: '',
REASON: '',
AMOUT: '',
DATE: formatDate(new Date(), 'yyyy-MM-dd hh:mm'),
},
}
},
onReady() {
@ -122,9 +190,21 @@ export default {
//
goToDetail(e) {
uni.navigateTo({
url: '/pages/application/key-project-management/penalty-management/detail?KEYPROJECTPUNISH_ID='+e + '&OUTSOURCED_ID=' + this.OUTSOURCED_ID + '&TabCur=' + (this.TabCur+1)
url: '/pages/application/key-project-management/hidden-management/detail?HIDDEN_ID=' + e +
'&OUTSOURCED_ID=' + this.OUTSOURCED_ID + '&TabCur=2'
});
},
fnModalShow(item) {
this.punishForm.HIDDEN_ID = item.HIDDEN_ID
this.punishForm.RECTIFICATIONDEPT_NAME = item.UNITS_NAME
this.punishForm.RECTIFICATIONOR_NAME = item.RECTIFICATIONOR_NAME
this.punishForm.ISPUNISH = '2'
this.modalShow = true
},
changeStartDate(e) {
this.punishForm.DATE = e
this.$forceUpdate(); //
},
getQuery(){ //
var _this = this;
_this.showCount = 10;
@ -154,7 +234,7 @@ export default {
title:"加载中..."
});//
uni.request({
url: basePath +'/app/keyprojectpunish/list?showCount='+_this.showCount+'&currentPage='+_this.currentPage,
url: basePath +'/app/keyprojectcheck/punishlist?showCount='+_this.showCount+'&currentPage='+_this.currentPage,
method: 'POST',
dataType: 'json',
header: {
@ -183,6 +263,91 @@ export default {
}
})
},
fnSubmit() {
var _this = this
console.log(this.punishForm)
//
if (this.punishForm.ISPUNISH === "1") {
for (const key in this.punishRules) {
if (!this.punishForm[key]) {
uni.showToast({
title: this.punishRules[key],
icon: 'none'
})
return
}
}
uni.request({
url: basePath + '/app/keyprojectpunish/add',
method: 'POST',
header: {
'Content-type': 'application/x-www-form-urlencoded'
},
data: {
...this.punishForm,
CORPINFO_ID: corpinfoId,
CREATOR: loginUserId,
OPERATOR: loginUserId,
},
success: (res) => {
if ("success" == res.data.result) {
_this.editHiddenIspunish(1);
_this.punishForm= {
HIDDEN_ID: '',
ISPUNISH: '',
RECTIFICATIONDEPT_NAME: '',
RECTIFICATIONOR_NAME: '',
REASON: '',
AMOUT: '',
DATE: formatDate(new Date(), 'yyyy-MM-dd hh:mm'),
}
} else {
uni.showToast({
title: res.data.msaesge,
duration: 2000
});
}
}
});
}else {
_this.editHiddenIspunish(2)
}
},
editHiddenIspunish(Ispunish){
//
uni.request({
url: basePath + '/app/keyprojectcheck/editHiddenIspunish',
method: 'POST',
header: {
'Content-type': 'application/x-www-form-urlencoded'
},
data: {
...this.punishForm,
ISPUNISH:Ispunish,
PUNISH_PERSON:loginUserId
},
success: (res) => {
this.modalShow = false
this.getQuery()
}
});
},
changeRadioGroup(e){
if(this.TabCur == 2) return
this.punishForm.ISPUNISH = e.detail.value
},
checkNumber(e){
var reg = /^[0-9]+(\.[0-9]{1,2})?$/;
if(!(reg.test(e.detail.value))){
uni.showToast({
title: "处罚金额只能输入整数或两位小数",
icon: 'none'
})
this.punishForm.AMOUT = 0;
}
}
}
}
</script>

View File

@ -23,6 +23,16 @@
<view v-for="(item,index) of list" :key="index" :data-id="item.INSPECTION_ID" @click="$noMultipleClicks(goToDetail,item.OUTSOURCED_ID)" class="dy-list-item p20">
<view class="dy-title-flex align-center">
<text>{{item.OUTSOURCED_NAME}}</text>
<text>
<view v-if="item.cfcount>0" style="border-radius: 96px;
font-size: 10px;
padding: 0px 10px;
height: 13px;
color: #ffffff;
background-color:#dd514c ;">
{{item.cfcount}}
</view>
</text>
</view>
<view v-show="item.IS_CORP_TYPE== '1'" class="dy-subtitle-flex">
<text>
@ -31,7 +41,7 @@
</view>
<view v-show="item.IS_CORP_TYPE== '1'" class="dy-subtitle-flex">
<text>
监督部门{{ item.Q_DEPARTMENT_NAME }}
监督部门{{ item.DEPARTMENT_NAME }}
</text>
</view>
<view v-show="item.IS_CORP_TYPE== '0'" class="dy-subtitle-flex">
@ -45,7 +55,7 @@
</text>
</view>
<view class="dy-subtitle-flex">
<text>相关方单位负责人{{item.UNITS_PIC}}</text>
<text>相关方单位负责人{{item.UNITS_PIC_NAME}}</text>
<text>电话{{item.UNITS_PHONE}}</text>
</view>
<view class="dy-subtitle-flex" style="height: 34upx;">
@ -161,7 +171,7 @@ export default {
title:"加载中..."
});//
uni.request({
url: basePath +'/app/keyProjects/listOutsourced?showCount='+_this.showCount+'&currentPage='+_this.currentPage ,
url: basePath +'/app/keyProjects/getPUNISHlist?showCount='+_this.showCount+'&currentPage='+_this.currentPage ,
method: 'POST',
dataType: 'json',
header: {
@ -170,7 +180,7 @@ export default {
data: {
KEYWORDS : _this.NameLikes, //
CORPINFO_ID:corpinfoId,
UserId:loginUserId
PUNISHUser:loginUserId
},
success: (res) => {
uni.hideLoading();//

View File

@ -324,15 +324,6 @@
</view>
</picker>
</view>
<!-- <view v-if="!hiddenForm.punishForm&&!punishFormType" class="done-btn" @click="punishFormType = true">
<text class="cu-btn bg-blue">添加罚单</text>
</view> -->
<!-- <view v-if="hiddenForm.punishForm||punishFormType">
<view class="done-btn" @click="punishFormType = false">
<text class="cu-btn bg-blue"> </text>
</view>
<punish-vue ref="punish" :ordPunishForm="this.hiddenForm.punishForm"></punish-vue>
</view> -->
<view style="display: flex;padding: 50upx 30upx 100upx 30upx">
<view style="flex: 1">
<button class="cu-btn" style="width: 95%;" @tap="cancelHidden"></button>
@ -506,7 +497,13 @@
value: 'hiddenLevel1004',
label: '轻微隐患'
}], //
PUNISHList: [{
value: '1',
label: '是'
}, {
value: '2',
label: '否'
}], //
hiddenTypeTreeList: [], //
hiddenType2TreeList: [], // 2
creatorList: [], //
@ -954,7 +951,6 @@
this.form.inspectorList[index].INSPECTION_USER_ID = this.inspectorList[index][e.detail.value].USER_ID;
this.form.inspectorList[index].INSPECTION_USER_NAME = this.inspectorList[index][e.detail.value].NAME;
},
addSituation() {
this.form.situationList.push({
INSPECTION_SITUATION_ID: '',

View File

@ -31,7 +31,7 @@
</view>
<view v-show="item.IS_CORP_TYPE== '1'" class="dy-subtitle-flex">
<text>
监督部门{{ item.Q_DEPARTMENT_NAME }}
监督部门{{ item.DEPARTMENT_NAME }}
</text>
</view>
<view v-show="item.IS_CORP_TYPE== '0'" class="dy-subtitle-flex">
@ -45,7 +45,7 @@
</text>
</view>
<view class="dy-subtitle-flex">
<text>相关方单位负责人{{item.UNITS_PIC}}</text>
<text>相关方单位负责人{{item.UNITS_PIC_NAME}}</text>
<text>电话{{item.UNITS_PHONE}}</text>
</view>
<view class="dy-subtitle-flex" style="height: 34upx;">
@ -170,7 +170,8 @@ export default {
data: {
KEYWORDS : _this.NameLikes, //
CORPINFO_ID:corpinfoId,
UserId:loginUserId
UserId:loginUserId,
STATE:'1'
},
success: (res) => {
uni.hideLoading();//

View File

@ -12,11 +12,11 @@
</view>
<view class="cu-form-group">
<view class="title">被处罚单位</view>
<input v-model="punishForm.RECTIFICATIONDEPT_NAME" placeholder="请输入被处罚单位"></input>
<input v-model="punishForm.RECTIFICATIONDEPT_NAME"></input>
</view>
<view class="cu-form-group">
<view class="title">被处罚人</view>
<input v-model="punishForm.RECTIFICATIONOR_NAME" placeholder="请输入被处罚人"></input>
<input v-model="punishForm.RECTIFICATIONOR_NAME"></input>
</view>
<view class="cu-form-group">
<view class="title">下发处罚时间</view>