433 lines
12 KiB
Vue
Executable File
433 lines
12 KiB
Vue
Executable File
<template>
|
||
<view class="report">
|
||
<opsoft-dialog-notice
|
||
:dialogNoticeShow="showDialog"
|
||
:dialogNoticeType="dialogNoticeType"
|
||
:dialogNoticeTitle="dialogNoticeTitle"
|
||
:dialogNoticeContent="dialogNoticeContent"
|
||
@dialogNoticeConfirmClick="dialogNoticeConfirmClick"
|
||
>
|
||
</opsoft-dialog-notice>
|
||
<view class="order-title">工单执行结果</view>
|
||
<view class="card-list" style="padding-left: 0;">
|
||
<view class="card-list-report">
|
||
<text class="card-info-item-text-none">总体评分:</text>
|
||
<!-- <text class="card-info-item-text-detail">{{FTotalScore}}</text> -->
|
||
<input v-model="FScore" placeholder="输入评分" placeholder-style="color:#8c8c8c;"
|
||
style="height: 34rpx; line-height: 34rpx; font-size: 28rpx;"/>
|
||
</view>
|
||
</view>
|
||
<view class="info-title">备件领用</view>
|
||
<view class="card-list" style="flex-direction: column;">
|
||
<view class="card-list-report" v-if="partList.length>0" v-for="(item,index) in partList" :key="index">
|
||
<view class="card-info-title-text-detail-left">{{item.FName}}</view>
|
||
<view class="card-info-title-text-detail-left-report">数量:{{item.FQty}}</view>
|
||
</view>
|
||
<view class="card-list-report" v-if="partList.length==0" @click="spareListClick">
|
||
<view class="card-info-item-text-none" style="text-align: left;">无领用</view>
|
||
</view>
|
||
</view>
|
||
<view class="info-title">维修人</view>
|
||
<view class="card-list" style="flex-direction: column;">
|
||
<view class="card-list-report" v-if="selWorker.length>0" v-for="(item,index) in selWorker" :key="index">
|
||
<view class="card-info-title-text-detail-left">{{item.FName}}</view>
|
||
<view class="card-info-title-text-detail-left-report">维修工时:{{item.FACraftTime?item.FACraftTime:0}}H
|
||
</view>
|
||
</view>
|
||
<view class="card-list-report" v-if="selWorker.length==0" @click="workerListClick">
|
||
<view class="card-info-item-text-none" style="text-align: left;">无维修人</view>
|
||
</view>
|
||
</view>
|
||
|
||
<view class="info-title">状态描述</view>
|
||
<view class="info-body">
|
||
<textarea placeholder="输入状态描述" v-model="FCondition" placeholder-class="text-area-holder"
|
||
class="text-area"></textarea>
|
||
</view>
|
||
<view class="info-title">备注</view>
|
||
<view class="info-body">
|
||
<textarea placeholder="输入备注信息" v-model="FExplain" placeholder-class="text-area-holder"
|
||
class="text-area"></textarea>
|
||
</view>
|
||
<view style="height: 200rpx;width: 100%;"></view>
|
||
<view @click="handleSubmit" class="btn-confirm" v-show="submitShow">验收</view>
|
||
</view>
|
||
</template>
|
||
<script>
|
||
import imgUpload from '@/components/poiuy-uImgUpload/imgUpload.vue';
|
||
import { pathToBase64, base64ToPath } from '@/js_sdk/mmmm-image-tools/index.js';
|
||
import opsoftDialogNotice from '@/components/opsoft-dialog-notice/opsoft-dialog-notice.vue';
|
||
import errorStrUntil from '@/common/errorStrUntil.js';
|
||
import Vue from 'vue';
|
||
import {
|
||
mapState,
|
||
mapMutations
|
||
} from 'vuex';
|
||
var commonUtil = require('../../../common/util.js');
|
||
export default {
|
||
computed: {
|
||
...mapState(['userInfo'])
|
||
},
|
||
components: {
|
||
imgUpload,
|
||
opsoftDialogNotice
|
||
},
|
||
|
||
data() {
|
||
return {
|
||
dialogNoticeContent:'',
|
||
dialogNoticeTitle:'',
|
||
dialogNoticeType:'',
|
||
showDialog:false,
|
||
|
||
FCondition:'',
|
||
FScore:'',
|
||
FExplain:'',
|
||
submitShow:true,
|
||
currRecordList:[],
|
||
ticketDataInfo:[],
|
||
FOrderStatus:0,
|
||
|
||
FContentAndRequir:'',
|
||
FNote:'',
|
||
partList:[],
|
||
workerList:[],
|
||
OrderEntryInfo:[],
|
||
FInterID:'',
|
||
|
||
FMaintManID:[],
|
||
FMachinePartID:'',
|
||
selWorker:[],
|
||
empNO:'',
|
||
imgArray:new Array(),
|
||
clickEnable:true,
|
||
imgBase64Url:new Array(),
|
||
|
||
dataList: [],
|
||
orgid:'',
|
||
commitList:[],
|
||
userID:'',
|
||
basicType:0,
|
||
equipID:'',
|
||
sparePartName:'',
|
||
|
||
};
|
||
},
|
||
|
||
onLoad(options) {
|
||
this.userID = this.userInfo.ID;
|
||
let equipInfo = uni.getStorageSync('firstPageAcceptenceCurItemInfoRepair');
|
||
this.equipID = equipInfo.FItemID;
|
||
this.currRecordList = uni.getStorageSync('currAcceptenceRecordListRepair');
|
||
this.ticketDataInfo = uni.getStorageSync('ticketDataAcceptenceInfoRepair');
|
||
this.orgid = uni.getStorageSync('orgid');
|
||
this.getReportInfo();
|
||
},
|
||
|
||
methods: {
|
||
dialogNoticeConfirmClick(){
|
||
this.showDialog = false;
|
||
},
|
||
dialogNoticeProps(err,type){
|
||
err = errorStrUntil.handle(err);
|
||
this.showDialog = true;
|
||
this.dialogNoticeType = 'error';
|
||
this.dialogNoticeTitle = '异常提示';
|
||
if(type=='success'){
|
||
this.dialogNoticeType = 'success';
|
||
this.dialogNoticeTitle = '执行成功';
|
||
}
|
||
this.dialogNoticeContent = err;
|
||
},
|
||
getReportInfo(count){
|
||
let _self = this;
|
||
let requestParams = {
|
||
"basicType":1,
|
||
"detailID":this.currRecordList.FDETAILID,
|
||
};
|
||
|
||
this.$request.get('/RepairOreder/MaintenanceOrderEntry',{params:requestParams}).then(res => {
|
||
let data = res;
|
||
this.FMaintManID = [];
|
||
if(data){
|
||
if(data.Body1.length>0){
|
||
this.OrderEntryInfo = data.Body1[0];
|
||
this.FOrderStatus = this.OrderEntryInfo.FORDERSTATUS;
|
||
if(this.FOrderStatus == 3){
|
||
this.submitShow = false;
|
||
}
|
||
this.FCondition = this.OrderEntryInfo.FCONDITION;
|
||
this.FScore = this.OrderEntryInfo.FSCORE;
|
||
this.FExplain = this.OrderEntryInfo.FEXPLAIN;
|
||
this.FMachinePartID = this.OrderEntryInfo.FMACHINEPARTID;
|
||
this.FInterID = this.OrderEntryInfo.FINTERID;
|
||
this.FContentAndRequir = this.OrderEntryInfo.FCONTENTSANDREQUIREMENTS;
|
||
this.FNote = this.OrderEntryInfo.FNOTE;
|
||
}
|
||
if(data.Body2.length>0){
|
||
data.Body2.forEach(
|
||
function(el){
|
||
let arr = {
|
||
FInterID:el.FSPAREPARTID,
|
||
FBillNO:_self.OrderEntryInfo.FBILLNO,
|
||
FName:el.FSPAREPARTNAME,
|
||
FEqModel:el.FEqModel,
|
||
FQty:el.FQTY
|
||
}
|
||
_self.partList.push(arr)
|
||
}
|
||
);
|
||
}
|
||
|
||
if(data.Body3.length>0){
|
||
data.Body3.forEach(
|
||
function(el){
|
||
let arr = {"FName":el.FEMPNAME,"FID":el.FMAINTMANID,"FACraftTime":el.FACRAFTTIME?el.FACRAFTTIME:0};
|
||
let arrID = {"FMaintID":el.FMAINTMANID,"FACraftTime":el.FACRAFTTIME?el.FACRAFTTIME:0};
|
||
_self.selWorker.push(arr);
|
||
_self.FMaintManID.push(arrID)
|
||
}
|
||
);
|
||
}
|
||
}
|
||
}).catch(err => {
|
||
uni.hideLoading();
|
||
this.dialogNoticeProps(err,'error')
|
||
});
|
||
},
|
||
|
||
handleSubmit(count){
|
||
let _self = this;
|
||
let data = [{"FInterID":this.FInterID,
|
||
"FDetailID":this.currRecordList.FDETAILID,
|
||
"FCondition":this.FCondition,
|
||
"FScore":this.FScore,
|
||
"FExplain":this.FExplain,
|
||
"FOrderStatus":this.FOrderStatus }];
|
||
let requestParams = {
|
||
"basicType":1,
|
||
"SData":data
|
||
};
|
||
|
||
this.$request.post('/RepairOreder/PartReportAcceptance',requestParams).then(res => {
|
||
uni.redirectTo({
|
||
url:'EQUM06Item'
|
||
})
|
||
}).catch(err => {
|
||
uni.hideLoading();
|
||
this.dialogNoticeProps(err,'error')
|
||
});
|
||
}
|
||
}
|
||
};
|
||
</script>
|
||
|
||
<style lang="scss">
|
||
page {
|
||
background-color: #F7F7F7;
|
||
overflow-x: hidden;
|
||
}
|
||
.report{overflow-x: hidden;}
|
||
.card-list-report {
|
||
position: relative;
|
||
width: 100%;
|
||
display: flex;
|
||
flex-direction: row;
|
||
flex-wrap: nowrap;
|
||
justify-content: flex-start;
|
||
align-items: center;
|
||
padding: 20rpx 0;
|
||
}
|
||
|
||
.card-info-title-text-detail-left-report {
|
||
position: absolute;
|
||
right: 0;
|
||
}
|
||
.alter{
|
||
position: fixed;
|
||
left: 0;
|
||
right: 0;
|
||
top:0;
|
||
bottom: 0;
|
||
background-color: #333333;
|
||
opacity: 0.5;
|
||
}
|
||
.err{
|
||
position: fixed;
|
||
left: 100rpx;
|
||
right: 100rpx;
|
||
top: 400rpx;
|
||
background-color: #FFFFFF;
|
||
border-radius: 20rpx;
|
||
opacity: 1;
|
||
z-index: 5;
|
||
}
|
||
.alter-head{
|
||
display: flex;
|
||
flex-wrap: nowrap;
|
||
}
|
||
.errTitle{
|
||
height: 80rpx;
|
||
line-height: 80rpx;
|
||
width: 100%;
|
||
font-size: 32rpx;
|
||
text-align: center;
|
||
border-bottom: 2rpx solid #3D3D3D;
|
||
}
|
||
.errTitle-search{
|
||
height: 80rpx;
|
||
line-height: 80rpx;
|
||
width: 100%;
|
||
color: #C0C0C0;
|
||
font-size: 28rpx;
|
||
text-align: center;
|
||
border-bottom: 2rpx solid #3D3D3D;
|
||
}
|
||
.errList{
|
||
width: 100%;
|
||
margin-left: 30%;
|
||
display: flex;
|
||
}
|
||
.errDetails{
|
||
/* width: 90%; */
|
||
font-size: 26rpx;
|
||
color: #3D3D3D;
|
||
}
|
||
.errConfirm{
|
||
height: 80rpx;
|
||
line-height: 80rpx;
|
||
width: 100%;
|
||
font-size: 32rpx;
|
||
text-align: center;
|
||
color: #007AFF;
|
||
border-top: 2rpx solid #3D3D3D;
|
||
}
|
||
.worker-alter{position: fixed;left: 0rpx;right: 0rpx;top: 300rpx;bottom: 0;
|
||
background-color: #FFFFFF;opacity: 1;z-index: 5;border-top-left-radius: 20rpx;border-top-right-radius: 20rpx;}
|
||
.worker-alter-head{display: flex;flex-direction: row;border-bottom: solid #F5F5F5 1px;}
|
||
.worker-alter-title{height: 100rpx;line-height: 100rpx;text-align: center;font-size: 32rpx;width: 100%;}
|
||
.worker-alter-list{display: flex;justify-content: space-between;align-items: center;padding: 20rpx 0;border-bottom: solid #F5F5F5 1px;}
|
||
.worker-alter-details{font-size: 26rpx;}
|
||
.worker-alter-time{font-size: 26rpx;display: flex;flex-direction: row;}
|
||
.worker-alter-time input{border: solid #F5F5F5 1px;border-radius: 10rpx;width: 100rpx;margin-right: 20rpx;text-align: center;}
|
||
.worker-alter-confirm{height: 80rpx;line-height: 80rpx;width: 100%;position: fixed;bottom: 0;
|
||
font-size: 32rpx;text-align: center;color: #FFFFFF;background-color: #007AFF;}
|
||
.sparePart{
|
||
position: fixed;
|
||
left: 0;
|
||
right: 0;
|
||
top: 300rpx;
|
||
bottom: 0;
|
||
background-color: #FFFFFF;
|
||
}
|
||
.top-row-class{
|
||
display: flex;
|
||
flex-wrap: nowrap;
|
||
justify-content: flex-start;
|
||
align-items: center;
|
||
height: 50rpx;
|
||
line-height: 50rpx;
|
||
// padding-top: 10rpx;
|
||
// padding-bottom: 10rpx;
|
||
// padding-left: 24rpx;
|
||
// padding-right: 24rpx;
|
||
margin-left: 32rpx;
|
||
margin-right: 32rpx;
|
||
flex-shrink: 0;
|
||
flex-grow: 0;
|
||
background-color: #FFFFFF;
|
||
margin-top: 10rpx;
|
||
margin-bottom: 16rpx;
|
||
border-radius: 10rpx;
|
||
}
|
||
.uni-input{
|
||
display: flex;
|
||
border: 1px solid #D8D8D8;
|
||
color: #666666;
|
||
padding: 5rpx 10rpx;
|
||
border-radius: 10rpx;
|
||
flex-wrap: nowrap;
|
||
overflow: hidden;
|
||
text-overflow: ellipsis;
|
||
white-space: nowrap;
|
||
word-break: break-all;
|
||
}
|
||
.top-row-title-class{
|
||
text-align: end;
|
||
font-size: 30rpx;
|
||
font-style: auto;
|
||
color: #666666;
|
||
flex-shrink: 0;
|
||
flex-grow: 0;
|
||
line-height: 50rpx;
|
||
height: 50rpx;
|
||
// width: 150rpx;
|
||
flex-wrap: nowrap;
|
||
}
|
||
.top-row-input-class{
|
||
position: relative;
|
||
font-size: 30rpx;
|
||
color: #6B6B6B;
|
||
width: 100%;
|
||
padding-left: 15rpx;
|
||
padding-right: 15rpx;
|
||
border-radius: 10rpx;
|
||
border: 1px solid #D8D8D8;
|
||
height: 60rpx; line-height: 60rpx;
|
||
margin-left: 32rpx;
|
||
}
|
||
.scanImg{
|
||
height: 40rpx;
|
||
width: 40rpx;
|
||
position: absolute;
|
||
right: 48rpx;
|
||
}
|
||
|
||
.inner {
|
||
display: flex;
|
||
padding: 4rpx 5% 10rpx 5%;
|
||
border-bottom: 1px solid #F7F7F7;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
}
|
||
|
||
.title-s {
|
||
color: #222222;
|
||
font-size: 14px;
|
||
}
|
||
|
||
.slave-s {
|
||
color: #858585;
|
||
font-size: 12px;
|
||
}
|
||
|
||
.slave-k {
|
||
color: #858585;
|
||
font-size: 12px;
|
||
display: flex;
|
||
justify-content: space-between;
|
||
}
|
||
.count-input{
|
||
height: 40rpx;
|
||
line-height: 40rpx;
|
||
width: 100rpx;
|
||
border: 1px solid #6D6D72;
|
||
border-radius: 10rpx;
|
||
margin: 0 10rpx;
|
||
text-align: center;
|
||
}
|
||
.confirmBtn{
|
||
height: 80rpx;
|
||
line-height: 80rpx;
|
||
width: 100%;
|
||
font-size: 32rpx;
|
||
color: #FFFFFF;
|
||
text-align: center;
|
||
background-color: #2560C9;
|
||
position: fixed;
|
||
bottom: 0;
|
||
}
|
||
</style>
|
||
|
||
</style>
|