Commit ba597542 by wusiyi

fix: 配货分拣点击配齐箱子不提示状态流转 #1002072

parent 9af2f98c
...@@ -1165,59 +1165,19 @@ const renderPrintResult = (printResult: string) => { ...@@ -1165,59 +1165,19 @@ const renderPrintResult = (printResult: string) => {
const handleOpened = () => { const handleOpened = () => {
productionOrderRef.value.focus() productionOrderRef.value.focus()
} }
const handleClose = (done: () => void) => {
nextStep(() => {
done()
})
}
const onClose = () => { const onClose = () => {
emit('refresh') emit('refresh')
} }
// 下一步
const nextStep = async (callback: () => void) => {
const everyPicked = podOrderDetailsData.value?.productList?.every(
(item) => item.count === item.purchaseNumber,
)
if (
everyPicked &&
isAutoPrint.value &&
(podOrderDetailsData.value?.printResult === 'printSuccess' ||
podOrderDetailsData.value?.printResult === 'notPrintSuccess')
) {
try {
await ElMessageBox.alert(
'当前订单验货完成并打印面单成功,是否转至待发货',
'提示',
{
confirmButtonText: '确定',
cancelButtonText: '取消',
},
)
submitInspection(() => {
callback && callback()
})
} catch (error) {
// 取消打单完成时仍允许切换箱子 / 关闭弹窗
callback && callback()
console.error(error)
}
} else {
callback && callback()
}
}
const handleBoxClick = (item: PodMakeOrderData) => { const handleBoxClick = (item: PodMakeOrderData) => {
const { box, data } = item const { box, data } = item
if (box == 0) return if (box == 0) return
isBillLading.value = !data?.filePath isBillLading.value = !data?.filePath
nextStep(() => {
if (!data) {
ElMessage.warning('暂无数据')
return
}
boxIndex.value = box || null boxIndex.value = box || null
boxChange.value = true boxChange.value = true
productionOrderRef.value.focus() productionOrderRef.value.focus()
})
} }
const handleClearBox = async () => { const handleClearBox = async () => {
try { try {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment