Browse Source

PDA采购收货任务执行,是否打印的开关

2024/6/19 14:41:46
pull/1/head
张立 6 months ago
parent
commit
9458c72085
  1. 3
      src/pages.json
  2. 2
      src/pages/index/index.vue
  3. 2
      src/pages/pointPutawayJob/index.vue
  4. 10
      src/pages/productPutaway/job/productPutawayDetail.vue
  5. 4
      src/pages/productPutaway/job/productPutawayJob.vue
  6. 1
      src/pages/productReceipt/job/fgProductReceiptDetail.vue
  7. 1
      src/pages/productReceipt/job/productReceiptDetail.vue
  8. 94
      src/pages/purchaseReceipt/job/receiptDetail.vue
  9. 1
      src/pages/putaway/job/putawayDetail.vue

3
src/pages.json

@ -902,7 +902,7 @@
{
"path": "pages/productPutaway/job/fgProductPutawayJob",
"style": {
"navigationBarTitleText": "装配上架任务",
"navigationBarTitleText": "成品入库任务",
"enablePullDownRefresh": true,
"titleNView": {
// "autoBackButton": "true",
@ -2074,7 +2074,6 @@
}
},
{
"path": "pages/check/checkFgLabel",
"style": {
"navigationBarTitleText": "标签成品标签",
"enablePullDownRefresh": false

2
src/pages/index/index.vue

@ -339,7 +339,7 @@ const getDictory = () => {
console.log('包装规格获取失败', res)
})
const switchCode = 'FgPutawayLocationCodeValidate,SemiPutawayLocationCodeValidate,PurchasePutawayToLocationCodeValidate,IssueToLocationCodeValidate,fgProductReceipCommitValidate'
const switchCode = 'FgPutawayLocationCodeValidate,SemiPutawayLocationCodeValidate,PurchasePutawayToLocationCodeValidate,IssueToLocationCodeValidate,fgProductReceipCommitValidate,purchasereceiptPrintPDA'
getSwitchByCode(switchCode)
.then((res) => {

2
src/pages/pointPutawayJob/index.vue

@ -33,7 +33,7 @@
<u-td>{{ cur.batch }}</u-td>
<u-td>{{ cur.packingNumber }}</u-td>
<u-td>{{ cur.packUnit }}</u-td>
<u-td>{{ cur.packQty }}</u-td>
<u-td>{{ cur.qty }}</u-td>
<u-td>{{ cur.uom }}</u-td>
</u-tr>
</u-table>

10
src/pages/productPutaway/job/productPutawayDetail.vue

@ -78,6 +78,7 @@ const type = ref('')
const isCheckLocation = ref(false)
const switchCode = ref('')
const scanedPackingNumber = ref('')
const hintTitle = ref('')
const status = ref('')
const scanPopup = ref()
const comScanLocation = ref()
@ -90,10 +91,12 @@ onLoad((option) => {
status.value = option.status || ''
if (type.value == 'predict') {
switchCode.value = 'SemiPutawayLocationCodeValidate'
updateTitle('预生产上架任务')
hintTitle.value = '预生产上架'
updateTitle('预生产上架详情')
} else if (type.value == 'assemble') {
hintTitle.value = '成品入库'
switchCode.value = 'FgPutawayLocationCodeValidate'
updateTitle('装配上架任务')
updateTitle('成品入库详情')
}
})
onShow(() => {
@ -171,6 +174,7 @@ const getDetail = () => {
s.scaned = true
s.cancleScanedHiht = true
openScanPopupSimulate(s)
scanedPackingNumber.value = ''
}
})
})
@ -355,7 +359,7 @@ const submitJob = () => {
.then((res) => {
uni.hideLoading()
if (res.data) {
showCommitSuccessMessage(`提交成功<br>生成制品上架记录:${res.data}`)
showCommitSuccessMessage(`提交成功<br>生成${hintTitle.value}记录<br>${res.data}`)
} else {
showErrorMessage(`提交失败[${res.msg}]`)
}

4
src/pages/productPutaway/job/productPutawayJob.vue

@ -127,7 +127,7 @@ const getList = (type) => {
if (props.type == 'predict') {
updateTitle(`预生产上架任务(${totalCount.value})`)
} else if (props.type == 'assemble') {
updateTitle(`装配上架任务(${totalCount.value})`)
updateTitle(`成品入库任务(${totalCount.value})`)
}
loadingType.value = 'loadmore'
if (list == null || list.length == 0) {
@ -144,7 +144,7 @@ const getList = (type) => {
if (props.type == 'predict') {
updateTitle(`预生产上架任务(${totalCount.value})`)
} else if (props.type == 'assemble') {
updateTitle(`装配上架任务(${totalCount.value})`)
updateTitle(`成品入库任务(${totalCount.value})`)
}
loadingType.value = ''
uni.hideLoading()

1
src/pages/productReceipt/job/fgProductReceiptDetail.vue

@ -187,6 +187,7 @@ const getDetail = () => {
s.scaned = true
//
scanPopup.value.simulateScan(s)
scanedPackingNumber.value = ''
}
})
})

1
src/pages/productReceipt/job/productReceiptDetail.vue

@ -187,6 +187,7 @@ const getDetail = () => {
s.cancleScanedHiht = true
s.copyContent = `HMQ;V1.0;I${s.itemCode};P${s.packingNumber};B${s.batch};Q${s.qty}`
scanPopup.value.simulateScan(s)
scanedPackingNumber.value = ''
// s.handleQty = s.qty
}
})

94
src/pages/purchaseReceipt/job/receiptDetail.vue

@ -55,7 +55,7 @@ import { ref, getCurrentInstance, nextTick } from 'vue'
import { onLoad, onShow, onNavigationBarButtonTap, onReady, onBackPress, onReachBottom, onPullDownRefresh } from '@dcloudio/uni-app'
import { purchaseReceiptJobSubmit, getPurchaseReceiptJobDetail, takePurchaseReceiptJob, cancleTakePurchaseReceiptJob, productDismantleJobClose, getPutawayJobList } from '@/api/request2.js'
import { goHome, getCurrDateTime, getPackingNumberAndBatch, compareAsc, navigateBack } from '@/common/basic.js'
import { goHome, getCurrDateTime, getPackingNumberAndBatch, compareAsc, navigateBack, getSwitchInfoByCode } from '@/common/basic.js'
import { getDirectoryItemArray } from '@/common/directory.js'
@ -91,6 +91,7 @@ const isAllReceived = ref(false)
const operation = ref('')
const scanedPackingNumber = ref('')
const status = ref('')
const switchCode = ref('')
const comMessageRef = ref()
const locationCompareRef = ref()
const scanPopup = ref()
@ -101,6 +102,7 @@ onLoad((option) => {
scanedPackingNumber.value = option.scaned || ''
status.value = option.status || ''
operation.value = option.operation
switchCode.value = 'purchasereceiptPrintPDA'
})
onShow(() => {
@ -182,6 +184,7 @@ const getDetail = () => {
s.cancleScanedHiht = true
s.copyContent = `HPQ;V1.0;I${s.itemCode};P${s.packingNumber};B${s.batch};Q${s.qty}`
scanPopup.value.simulateScan(s)
scanedPackingNumber.value = ''
}
})
})
@ -391,50 +394,57 @@ const submitJob = () => {
uni.hideLoading()
if (res.data) {
// showCommitSuccessMessage(`<br><br>${res.data}`)
uni.showLoading({
title: '提交成功,将跳转到打印页面',
mask: true
})
//
let timerCount = 0
const timer1 = setInterval(async () => {
if (timerCount == 15) {
clearInterval(timer1)
uni.showToast({
title: '跳转打印页面失败',
icon: 'none'
})
return
}
await getPutawayJobList({
filters: [
{
column: 'purchaseReceiptRecordNumber',
action: 'in',
value: res.data.number
}
],
pageNo: 1,
pageSize: 1000
}).then((res1) => {
timerCount += 1
if (res1.data && res1.data.list && res1.data.list.length && res1.data.total >= res.data.detailCount) {
uni.hideLoading()
const isCheckPrint = getSwitchInfoByCode(switchCode.value)
if (!isCheckPrint) {
uni.hideLoading()
showCommitSuccessMessage(`提交成功<br>生成采购收货记录<br>${res.data.number}`)
} else {
uni.showLoading({
title: '提交成功,将跳转到打印页面',
mask: true
})
//
let timerCount = 0
const timer1 = setInterval(async () => {
if (timerCount == 15) {
clearInterval(timer1)
const dataParams = {
toLocationCode: res1.data.list[0].toLocationCode,
number: res1.data.list[0].number,
creator: res1.data.list[0].creator,
createTime: res1.data.list[0].createTime,
ids: res1.data.list.map((item) => item.masterId).join(',')
}
console.log(dataParams)
uni.navigateTo({
url: `/pages/pointPutawayJob/index?data=${encodeURIComponent(JSON.stringify(dataParams))}`
uni.showToast({
title: '跳转打印页面失败',
icon: 'none'
})
return
}
})
}, 2000)
await getPutawayJobList({
filters: [
{
column: 'purchaseReceiptRecordNumber',
action: 'in',
value: res.data.number
}
],
pageNo: 1,
pageSize: 1000
}).then((res1) => {
timerCount += 1
if (res1.data && res1.data.list && res1.data.list.length && res1.data.total >= res.data.detailCount) {
uni.hideLoading()
clearInterval(timer1)
const dataParams = {
toLocationCode: res1.data.list[0].toLocationCode,
number: res1.data.list[0].number,
creator: res1.data.list[0].creator,
createTime: res1.data.list[0].createTime,
ids: res1.data.list.map((item) => item.masterId).join(',')
}
console.log(dataParams)
uni.navigateTo({
url: `/pages/pointPutawayJob/index?data=${encodeURIComponent(JSON.stringify(dataParams))}`
})
}
})
}, 2000)
}
} else {
showErrorMessage(`提交失败[${res.msg}]`)
}

1
src/pages/putaway/job/putawayDetail.vue

@ -163,6 +163,7 @@ const getDetail = () => {
s.packList.forEach((item) => (item.scaned = true))
s.inventoryStatus = s.inspectResult //
openScanPopupSimulate(s)
scanedPackingNumber.value = ''
}
})
})

Loading…
Cancel
Save