mirror of
https://github.com/fjykTec/ModernWMS.git
synced 2026-06-19 07:36:14 +00:00
feat(收货管理): 分拣时没填到期时间无法保存
This commit is contained in:
@@ -70,6 +70,7 @@ import { hookComponent } from '@/components/system/index'
|
||||
import { IsInteger, StringLength } from '@/utils/dataVerification/formRule'
|
||||
import { errorColor } from '@/constant/style'
|
||||
import tooltipBtn from '@/components/tooltip-btn.vue'
|
||||
import { removeObjectNull } from '@/utils/common'
|
||||
|
||||
const formRef = ref()
|
||||
const emit = defineEmits(['sure'])
|
||||
@@ -136,25 +137,29 @@ const method = reactive({
|
||||
const reqData: any = []
|
||||
|
||||
for (const item of data.SNList) {
|
||||
reqData.push({
|
||||
let sureItem = {
|
||||
asn_id: data.form.asn_id,
|
||||
expiry_date: data.form.expiry_date,
|
||||
series_number: item.snNum,
|
||||
sorted_qty: 1,
|
||||
is_auto_num: data.is_auto_num
|
||||
})
|
||||
}
|
||||
sureItem = removeObjectNull(sureItem)
|
||||
reqData.push(sureItem)
|
||||
}
|
||||
|
||||
// If there is still remaining after removing the SN code, add details without the SN code
|
||||
if (data.SNList.length !== data.form.sorted_qty) {
|
||||
const margin = data.form.sorted_qty - data.SNList.length
|
||||
reqData.push({
|
||||
let sureItem = {
|
||||
asn_id: data.form.asn_id,
|
||||
expiry_date: data.form.expiry_date,
|
||||
series_number: '',
|
||||
sorted_qty: margin,
|
||||
is_auto_num: data.is_auto_num
|
||||
})
|
||||
}
|
||||
sureItem = removeObjectNull(sureItem)
|
||||
reqData.push(sureItem)
|
||||
}
|
||||
|
||||
emit('sure', reqData)
|
||||
|
||||
Reference in New Issue
Block a user