|
@ -30,7 +30,7 @@ |
|
|
<scroll-view scroll-y="true" class="page-main-scroll"> |
|
|
<scroll-view scroll-y="true" class="page-main-scroll"> |
|
|
<view> |
|
|
<view> |
|
|
<comDeliverDetailCardBatch ref='comIssueDetailCard' :dataContent="detailSource" :settingParam="jobContent" |
|
|
<comDeliverDetailCardBatch ref='comIssueDetailCard' :dataContent="detailSource" :settingParam="jobContent" |
|
|
@updateData='updateData'> |
|
|
@updateData='updateData' :allowBiggerQty='allowBiggerQty'> |
|
|
</comDeliverDetailCardBatch> |
|
|
</comDeliverDetailCardBatch> |
|
|
</view> |
|
|
</view> |
|
|
</scroll-view> |
|
|
</scroll-view> |
|
@ -109,7 +109,8 @@ |
|
|
scanOptions: [], |
|
|
scanOptions: [], |
|
|
status: "", |
|
|
status: "", |
|
|
toLocationCode: "", |
|
|
toLocationCode: "", |
|
|
jobStatus: "" |
|
|
jobStatus: "", |
|
|
|
|
|
allowBiggerQty:true,//开启数量校验提示 |
|
|
}; |
|
|
}; |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -186,6 +187,7 @@ |
|
|
that.subList = res.data.subList; |
|
|
that.subList = res.data.subList; |
|
|
that.detailSource = res.data; |
|
|
that.detailSource = res.data; |
|
|
that.toLocationCode = that.subList[0].toLocationCode |
|
|
that.toLocationCode = that.subList[0].toLocationCode |
|
|
|
|
|
that.allowBiggerQty = res.data.allowBiggerQty; |
|
|
that.resizeCollapse(); |
|
|
that.resizeCollapse(); |
|
|
} else { |
|
|
} else { |
|
|
that.showMessage('未获取到详情'); |
|
|
that.showMessage('未获取到详情'); |
|
@ -247,6 +249,7 @@ |
|
|
|
|
|
|
|
|
checkCount() { |
|
|
checkCount() { |
|
|
let str = "" |
|
|
let str = "" |
|
|
|
|
|
let str1 = "" |
|
|
var taskQty = 0; |
|
|
var taskQty = 0; |
|
|
var totalQty = 0; |
|
|
var totalQty = 0; |
|
|
this.detailSource.subList.forEach(item => { |
|
|
this.detailSource.subList.forEach(item => { |
|
@ -260,8 +263,13 @@ |
|
|
//如果允许部分提交任务有扫描记录就可以直接提交;如果不允许部分执行,任务数量和提交数量不一致给出提示 |
|
|
//如果允许部分提交任务有扫描记录就可以直接提交;如果不允许部分执行,任务数量和提交数量不一致给出提示 |
|
|
this.detailSource.subList.forEach(detail => { |
|
|
this.detailSource.subList.forEach(detail => { |
|
|
if (this.jobContent.allowPartialComplete == "FALSE") { |
|
|
if (this.jobContent.allowPartialComplete == "FALSE") { |
|
|
if (item.taskQty != item.totalQty) { |
|
|
if (taskQty != totalQty) { |
|
|
str += `物料号【${item.itemCode}】任务数量【${item.taskQty}】与实际提交数量【${item.totalQty}】不一致\n` |
|
|
str += `物料号【${detail.itemCode}】任务数量【${taskQty}】与实际提交数量【${totalQty}】不一致\n` |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
if (this.allowBiggerQty) { |
|
|
|
|
|
if (taskQty > totalQty) { |
|
|
|
|
|
str1 += '数量[' + totalQty + ']不允许大于任务数量[' + taskQty + ']' |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
@ -270,8 +278,12 @@ |
|
|
str = '不允许提交\n' + str |
|
|
str = '不允许提交\n' + str |
|
|
this.showErrorMessage(str) |
|
|
this.showErrorMessage(str) |
|
|
} |
|
|
} |
|
|
|
|
|
if (str1) { |
|
|
|
|
|
str = '不允许提交\n' + str |
|
|
|
|
|
this.showErrorMessage(str) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
return str ? false : true |
|
|
return str || str1 ? false : true |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -291,6 +303,7 @@ |
|
|
deliverJobSubmit(params).then(res => { |
|
|
deliverJobSubmit(params).then(res => { |
|
|
uni.hideLoading() |
|
|
uni.hideLoading() |
|
|
if (res.data) { |
|
|
if (res.data) { |
|
|
|
|
|
|
|
|
this.showCommitSuccessMessage("提交成功\n生成发货记录\n" + res.data) |
|
|
this.showCommitSuccessMessage("提交成功\n生成发货记录\n" + res.data) |
|
|
} else { |
|
|
} else { |
|
|
this.showErrorMessage("提交失败[" + res.msg + "]") |
|
|
this.showErrorMessage("提交失败[" + res.msg + "]") |
|
|