|
|
@@ -152,7 +152,7 @@
|
|
|
|
|
|
|
|
|
<view class="item ww40" v-if='isDetails'>
|
|
|
- {{it.extInfo.taskName}}
|
|
|
+ {{ yy.taskName}}
|
|
|
</view>
|
|
|
|
|
|
<view class="item ww40" v-else>
|
|
|
@@ -175,6 +175,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+ <view class="content_table2">
|
|
|
+ <view class="head row rx-sc">
|
|
|
+ <view class="item ww15" style="font-size: 20rpx;">
|
|
|
+ 不合格数
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="item ww15" style="font-size: 20rpx;">
|
|
|
+ 重量
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="item ww25">类型</view>
|
|
|
+
|
|
|
+ <view class="item ww35 rx-bc">
|
|
|
+ <text>处置/原因</text>
|
|
|
+ <image v-if='!isDetails' class="icon" @click="handAddListPL4(it, idx)"
|
|
|
+ src="~@/static/pda/add.svg" style="width: 46rpx;height: 46rpx;margin-right: 12rpx;"></image>
|
|
|
+
|
|
|
+ </view>
|
|
|
+ <view class="item ww10 ">
|
|
|
+ 操作
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="table">
|
|
|
+ <view class="tr row rx-sc" v-for="(yy, yyIdx) in it.extInfo.notBatchReportInfo" :key="'not'+ idx + yyIdx">
|
|
|
+ <view class="item ww15 content_num">
|
|
|
+ <view v-if='isDetails'>{{yy.allFeedQuantity }}</view>
|
|
|
+ <input class="uni-input" v-else v-model="yy.allFeedQuantity"
|
|
|
+ @input="blurNum2($event,idx, yyIdx)" type='number'></input>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="item ww15 content_num">
|
|
|
+ <view v-if='isDetails'>{{yy.allReportWeight }}</view>
|
|
|
+ <input class="uni-input" v-else v-model="yy.allReportWeight"
|
|
|
+ type='number'></input>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="item ww25 content_num">
|
|
|
+ <zxz-uni-data-select :localdata="notTypeList" v-model="yy.notType" dataValue='code'
|
|
|
+ format='{name}' dataKey="code" filterable :disabled="isDetails" @change="handLoad()"
|
|
|
+ :clear='false'></zxz-uni-data-select>
|
|
|
+ </view>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ <view class="item ww35" v-if='isDetails'>
|
|
|
+ {{ yy.notType == 5 ? yy.taskName : yy.notReason}}
|
|
|
+ </view>
|
|
|
+
|
|
|
+
|
|
|
+ <view class="item ww35 content_num" v-if="!isDetails && yy.notType == 5">
|
|
|
+
|
|
|
+ <zxz-uni-data-select :localdata="stepsList" v-model="yy.taskId" dataValue='taskId'
|
|
|
+ format='{taskTypeName}' dataKey="taskId" filterable
|
|
|
+ @change=" e => yy.taskName = e.taskTypeName" :clear='false'></zxz-uni-data-select>
|
|
|
+
|
|
|
+
|
|
|
+ </view>
|
|
|
+ <view class="item ww35 content_num" v-if="!isDetails && yy.notType != 5">
|
|
|
+ <input class="uni-input" v-if="yy.notType != 5 " v-model="yy.notReason"></input>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="item ww10">
|
|
|
+ <uni-icons v-if='!isDetails' custom-prefix="iconfont" type="icon-shanchu" size="16"
|
|
|
+ @click="handDel4(idx, yyIdx)" color="#fa3534"></uni-icons>
|
|
|
+ </view>
|
|
|
+
|
|
|
+
|
|
|
+ </view>
|
|
|
+
|
|
|
+ </view>
|
|
|
+
|
|
|
+ </view>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
</view>
|
|
|
|
|
|
|
|
|
@@ -239,7 +317,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
- deviceList: []
|
|
|
+ deviceList: [],
|
|
|
+
|
|
|
+ notTypeList: [{
|
|
|
+ code: "1",
|
|
|
+ name: '返工'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: "2",
|
|
|
+ name: '返修'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: "3",
|
|
|
+ name: '报废'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: '4',
|
|
|
+ name: '降级使用'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: "5",
|
|
|
+ name: '让步接收'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
|
@@ -251,6 +353,7 @@
|
|
|
|
|
|
this.getSteps()
|
|
|
|
|
|
+ console.log(this.list)
|
|
|
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -277,6 +380,7 @@
|
|
|
taskId: '',
|
|
|
taskName: ''
|
|
|
})
|
|
|
+ this.$forceUpdate()
|
|
|
},
|
|
|
|
|
|
handDel3(idx, yyIdx) {
|
|
|
@@ -293,14 +397,20 @@
|
|
|
this.list[idx].extInfo.batchReportInfo.forEach(m => {
|
|
|
count = count + Number(m.allFeedQuantity || 0)
|
|
|
})
|
|
|
+
|
|
|
+ let count2 = 0
|
|
|
+ this.list[idx].extInfo.notBatchReportInfo.forEach(m => {
|
|
|
+ count2 = count2 + Number(m.allFeedQuantity || 0)
|
|
|
+ })
|
|
|
+
|
|
|
|
|
|
- if (count > this.list[idx].feedQuantity) {
|
|
|
+ if (Number(count + count2) > this.list[idx].feedQuantity) {
|
|
|
|
|
|
this.$set(this.list[idx].extInfo.batchReportInfo[yyIdx], 'allFeedQuantity', 0)
|
|
|
this.$forceUpdate()
|
|
|
|
|
|
uni.showToast({
|
|
|
- title: `投料合格品数不能大于投料数量`,
|
|
|
+ title: `投料数不能大于投料数量`,
|
|
|
icon: 'none'
|
|
|
})
|
|
|
|
|
|
@@ -308,6 +418,39 @@
|
|
|
}
|
|
|
|
|
|
},
|
|
|
+
|
|
|
+
|
|
|
+ blurNum2(event, idx, yyIdx) {
|
|
|
+
|
|
|
+ let value = event.target.value;
|
|
|
+ value = value.replace(/\./g, '');
|
|
|
+ this.$set(this.list[idx].extInfo.notBatchReportInfo[yyIdx], 'allFeedQuantity', value);
|
|
|
+
|
|
|
+ let count = 0
|
|
|
+ this.list[idx].extInfo.batchReportInfo.forEach(m => {
|
|
|
+ count = count + Number(m.allFeedQuantity || 0)
|
|
|
+ })
|
|
|
+
|
|
|
+ let count2 = 0
|
|
|
+ this.list[idx].extInfo.notBatchReportInfo.forEach(m => {
|
|
|
+ count2 = count2 + Number(m.allFeedQuantity || 0)
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
+ if (Number(count + count2) > this.list[idx].feedQuantity) {
|
|
|
+
|
|
|
+ this.$set(this.list[idx].extInfo.notBatchReportInfo[yyIdx], 'allFeedQuantity', 0)
|
|
|
+ this.$forceUpdate()
|
|
|
+
|
|
|
+ uni.showToast({
|
|
|
+ title: `投料数不能大于投料数量`,
|
|
|
+ icon: 'none'
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ },
|
|
|
|
|
|
|
|
|
getDelete2(idx) {
|
|
|
@@ -324,6 +467,27 @@
|
|
|
})
|
|
|
},
|
|
|
|
|
|
+ handAddListPL4(it, idx) {
|
|
|
+ this.list[idx].extInfo.notBatchReportInfo.push({
|
|
|
+ allFeedQuantity: '',
|
|
|
+ allReportWeight: '',
|
|
|
+ notType: '',
|
|
|
+ taskId: '',
|
|
|
+ taskName: '',
|
|
|
+ notReason: ''
|
|
|
+ })
|
|
|
+ this.$forceUpdate()
|
|
|
+ },
|
|
|
+
|
|
|
+ handDel4(idx, yyIdx) {
|
|
|
+ this.list[idx].extInfo.notBatchReportInfo.splice(yyIdx, 1)
|
|
|
+ this.$forceUpdate()
|
|
|
+ },
|
|
|
+
|
|
|
+ handLoad() {
|
|
|
+ this.$forceUpdate()
|
|
|
+ },
|
|
|
+
|
|
|
|
|
|
|
|
|
changeHeatNumber() {
|
|
|
@@ -560,6 +724,10 @@
|
|
|
width: 25%;
|
|
|
}
|
|
|
|
|
|
+ .ww35 {
|
|
|
+ width: 35%;
|
|
|
+ }
|
|
|
+
|
|
|
.ww50 {
|
|
|
width: 50%;
|
|
|
}
|