diff --git a/pages/zw/jb-lower-mater.vue b/pages/zw/jb-lower-mater.vue
index de8a77e..730f586 100644
--- a/pages/zw/jb-lower-mater.vue
+++ b/pages/zw/jb-lower-mater.vue
@@ -37,6 +37,15 @@
+
+
+ 人工转运
+
+
+
+
+
+
@@ -108,6 +117,7 @@
dupWeight: '',
orgWeight: '',
standError: '',
+ isChecked: false,
disabled: false,
statusMap: {
'1': '未生产',
@@ -240,11 +250,13 @@
toChek (e) {
this.pkId = this.pkId === e.workorder_id ? '' : e.workorder_id
this.pkObj = this.pkId === e.workorder_id ? e : {}
+ this.getWeight()
},
clearUp () {
this.index2 = ''
this.val2 = ''
this.val3 = ''
+ this.isChecked = false
this.dataList = []
this.pageNum = 1
this.pkId = ''
@@ -277,11 +289,13 @@
}
},
xlconfirm () {
+ console.log(1)
+ console.log(this.flag, 'flag')
this.disabled = true
- if (!this.index2 || !this.val3 || !this.val2 || !this.pkId) {
- this.disabled = false
- return
- }
+ // if (!this.index2 || !this.val3 || !this.val2 || !this.pkId) {
+ // this.disabled = false
+ // return
+ // }
if (this.flag === '2') {
let chazhi = Number(this.val3) - Number(this.orgWeight)
if ( chazhi > Number(this.standError)) {
@@ -298,6 +312,7 @@
}
})
} else {
+ console.log(2)
this._downMaterial()
}
}
@@ -323,7 +338,8 @@
},
async _downMaterial () {
try {
- let res = await downMaterial(this.pkId, 'DDJBQ', this.val3, this.index2, this.val1, this.val2)
+ let check = this.isChecked ? '1' : '0'
+ let res = await downMaterial(this.pkId, 'DDJBQ', this.val3, this.index2, this.val1, this.val2, check)
if (res.code === '200') {
uni.showToast({
title: res.message,
@@ -340,6 +356,9 @@
} catch (e) {
this.disabled = false
}
+ },
+ setWStatus () {
+ this.isChecked = !this.isChecked
}
}
}
diff --git a/utils/getData4.js b/utils/getData4.js
index a293b22..024a3d7 100644
--- a/utils/getData4.js
+++ b/utils/getData4.js
@@ -161,9 +161,9 @@ export const getWeight = (pcode, wid) => request({
data: {point_code: pcode, workorder_id: wid}
})
// 下料
-export const downMaterial = (wid, area, weight, pcode, tcode, lcode) => request({
+export const downMaterial = (wid, area, weight, pcode, tcode, lcode, type) => request({
url:'api/pda/jb/downMaterial',
- data: {workorder_id: wid, area: area, weight: weight, point_code: pcode, tp_code: tcode, lt_code: lcode}
+ data: {workorder_id: wid, area: area, weight: weight, point_code: pcode, tp_code: tcode, lt_code: lcode, type: type}
})
// 获取解包点位的托盘编码
export const jbGetVehicleCode = (pcode) => request({