Browse Source

修改备货任务扫描其他批次选不中 2024/7/4 19:18:30

hella_vue3
zhang_li 3 months ago
parent
commit
9dbe73d0b5
  1. 62
      src/mycomponents/balance/balanceSelect.vue
  2. 2
      src/mycomponents/scan/winScanPackAndLocation.vue
  3. 2
      src/pages/deliver/coms/comScanDeliverPack.vue
  4. 8
      src/pages/productionReturn/coms/comScanReturnPack.vue
  5. 1
      src/pages/repleinsh/record/directRepleinshRecord.vue
  6. 10
      src/pages/stockUp/coms/comScanStockUpPack.vue

62
src/mycomponents/balance/balanceSelect.vue

@ -1,41 +1,37 @@
<!--发料任务卡片--> <!--发料任务卡片-->
<template> <template>
<!-- <page-meta root-font-size="18px"></page-meta> --> <!-- <page-meta root-font-size="18px"></page-meta> -->
<u-popup v-model='show' mode='center'> <u-popup v-model="show" mode="center">
<scroll-view scroll-y="true" style="background-color: #EEEEEE;height: 90vh;"> <scroll-view scroll-y="true" style="background-color: #eeeeee; height: 90vh">
<item :dataContent="balanceItems[0]"></item> <item style="margin: 10rpx" :dataContent="balanceItems[0]"></item>
<view class="popinpop count_shadow" style="width: 90vw;margin: 20rpx 20rpx 30rpx 20rpx;" <view class="popinpop count_shadow" style="width: 90vw; margin: 20rpx 20rpx 30rpx 20rpx" v-for="(item, index) in balanceItems" :key="item.id" @click="callback(item)">
v-for="(item, index) in balanceItems" :key="item.id" @click="callback(item)"> <balance :dataContent="item" :isShowStatus="false"></balance>
<balance :dataContent="item"></balance> </view>
</view> </scroll-view>
</scroll-view> </u-popup>
</u-popup>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import { import { ref, getCurrentInstance } from 'vue'
ref, import item from '@/mycomponents/item/item.vue'
getCurrentInstance, import balance from '@/mycomponents/balance/balance.vue'
} from 'vue'
import item from '@/mycomponents/item/item.vue'
import balance from '@/mycomponents/balance/balance.vue'
const balanceItems = ref([])
const openPopup = (items) => {
if(Array.isArray(items)){
balanceItems.value= items;
}else{
balanceItems.value = [items];
}
show.value = true
}
const callback = (item) => { const balanceItems = ref([])
emit("onSelectItem", item); const openPopup = (items) => {
show.value = false if (Array.isArray(items)) {
} balanceItems.value = items
const emit = defineEmits(['onSelectItem']) } else {
defineExpose({openPopup}) balanceItems.value = [items]
}
show.value = true
}
const callback = (item) => {
emit('onSelectItem', item)
show.value = false
}
const emit = defineEmits(['onSelectItem'])
defineExpose({ openPopup })
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss"></style>
</style>

2
src/mycomponents/scan/winScanPackAndLocation.vue

@ -128,7 +128,7 @@ const openScanPopupForType = (fromLocationCodeParams, businessTypeParams) => {
} }
fromInventoryStatuses.value = getDirectoryItemArray(businessType.value.outInventoryStatuses) fromInventoryStatuses.value = getDirectoryItemArray(businessType.value.outInventoryStatuses)
inventoryStatus.value = getDirectoryItemArray(businessType.value.outInventoryStatuses) // inventoryStatus.value = getDirectoryItemArray(businessType.value.outInventoryStatuses) //
fromLocationAreaTypeList.value = getDirectoryItemArray(businessType.value.fromLocationAreaTypeList) // fromLocationAreaTypeList.value = getDirectoryItemArray(businessType.value.outAreaTypes) //
if (!show.value) { if (!show.value) {
setTimeout((res) => { setTimeout((res) => {
show.value = true show.value = true

2
src/pages/deliver/coms/comScanDeliverPack.vue

@ -263,7 +263,7 @@ const afterGetBalance = (label, balance, packageInfo) => {
getfocus() getfocus()
}) })
} }
} else if (jobContent.value.AllowModifyBatch == null) { } else if (jobContent.value.allowModifyBatch == 'TRUE') {
showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发货明细,是否要继续发货?`, (res) => { showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发货明细,是否要继续发货?`, (res) => {
if (res) { if (res) {
const batch = createBatchInfo(label, balance, packageInfo) const batch = createBatchInfo(label, balance, packageInfo)

8
src/pages/productionReturn/coms/comScanReturnPack.vue

@ -238,10 +238,10 @@ const afterGetBalance = (label, balance, packageInfo) => {
getfocus() getfocus()
}) })
} }
} else if (jobContent.value.AllowModifyBatch == null) { } else if (jobContent.value.allowModifyBatch == "TRUE") {
showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发料明细,是否要继续发料?`, (res) => { showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发料明细,是否要继续发料?`, (res) => {
if (res) { if (res) {
const batch = createBatchInfo(label, balance) const batch = createBatchInfo(label, balance,packageInfo))
fromLocation.Batchs.unshift(batch) fromLocation.Batchs.unshift(batch)
} }
}) })
@ -261,7 +261,7 @@ const afterGetBalance = (label, balance, packageInfo) => {
}) })
} }
} }
const createBatchInfo = (data, balance) => { const createBatchInfo = (data, balance,packageInfo) => {
const batch = { const batch = {
batch: data.batch, batch: data.batch,
qty: 0, qty: 0,
@ -269,7 +269,7 @@ const createBatchInfo = (data, balance) => {
handleQty: Number(data.qty), handleQty: Number(data.qty),
Records: [] Records: []
} }
const record = creatRecord(data, balance) const record = creatRecord(data, balance,packageInfo)
batch.Records.push(record) batch.Records.push(record)
issueRecord.value.unshift(record) issueRecord.value.unshift(record)
return batch return batch

1
src/pages/repleinsh/record/directRepleinshRecord.vue

@ -96,7 +96,6 @@ onLoad((option) => {
getBusinessType(businessTypeCode.value, (res) => { getBusinessType(businessTypeCode.value, (res) => {
if (res.success) { if (res.success) {
businessType.value = res.businessType businessType.value = res.businessType
res.fromLocationAreaTypeList.push('INSPECT', 'SUPPER')
fromLocationAreaTypeList.value = res.fromLocationAreaTypeList fromLocationAreaTypeList.value = res.fromLocationAreaTypeList
toLocationAreaTypeList.value = res.toLocationAreaTypeList toLocationAreaTypeList.value = res.toLocationAreaTypeList
showFromLocationPopup() showFromLocationPopup()

10
src/pages/stockUp/coms/comScanStockUpPack.vue

@ -218,12 +218,12 @@ const onScan = (result) => {
showBalanceSelect(balanceRes.data.list, packageInfo) showBalanceSelect(balanceRes.data.list, packageInfo)
} }
} else { } else {
showErrorMessage(balanceRes.message.message) showErrorMessage(balanceRes.message)
} }
uni.hideLoading() uni.hideLoading()
}) })
} catch (e) { } catch (error) {
showErrorMessage(e.stack) showErrorMessage(error)
uni.hideLoading() uni.hideLoading()
} }
} }
@ -270,7 +270,7 @@ const afterGetBalance = (label, balance, packageInfo) => {
getfocus() getfocus()
}) })
} }
} else if (jobContent.value.AllowModifyBatch == null) { } else if (jobContent.value.allowModifyBatch == 'TRUE') {
showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发货明细,是否要继续发货?`, (res) => { showQuestionMessage(`在【${fromLocationCode.value}】库位下,未查找到批次【${lot}】的发货明细,是否要继续发货?`, (res) => {
if (res) { if (res) {
const batch = createBatchInfo(label, balance, packageInfo) const batch = createBatchInfo(label, balance, packageInfo)
@ -295,7 +295,7 @@ const afterGetBalance = (label, balance, packageInfo) => {
} }
const createBatchInfo = (data, balance, packageInfo) => { const createBatchInfo = (data, balance, packageInfo) => {
const batch = { const batch = {
batch: data.lot, batch: data.batch,
qty: 0, qty: 0,
uom: data.uom, uom: data.uom,
handleQty: Number(data.qty), handleQty: Number(data.qty),

Loading…
Cancel
Save