Commit ec17d100 by linjinhong

批量下载添加打印拣货单

parent c89da26c
......@@ -563,3 +563,14 @@ export function getAccountCodeByFactoryIdApi(params: { token: string }) {
params,
})
}
// 打印拣货单item
export function printPickPdfByBatchNumberApi(params: {
batchArrangeNumber: string
}) {
return axios.get<never, BaseRespData<never>>(
`factory/podJomallOrderProductUs/printPickPdfByBatchNumber`,
{
params,
},
)
}
......@@ -1448,6 +1448,15 @@
<span class="operate-item">
<ElButton
link
type="primary"
@click="printPickingOrderItem(row)"
>
打印拣货单
</ElButton>
</span>
<span class="operate-item">
<ElButton
link
type="warning"
:loading="reComposingLoadingMap[row.id]"
@click="handleReComposingDesign(row)"
......@@ -1611,7 +1620,6 @@
</span>
</template>
<template #operations>
<div
v-if="cardItem?.customizedQuantity"
class="customizedQuantity"
......@@ -1653,15 +1661,12 @@
/>
</div>
</div>
<div
v-if="cardItem.platform"
>
<img
:src="`/images/icon/${getPlatformImg(cardItem.platform)}`"
style="height: 30px"
/>
</div>
<div v-if="cardItem.platform">
<img
:src="`/images/icon/${getPlatformImg(cardItem.platform)}`"
style="height: 30px"
/>
</div>
</div>
</template>
<template #info>
......@@ -1775,7 +1780,6 @@
</span>
</div>
<!-- <div class="grid-item" title="订单号">
<span
class="grid-item-value"
......@@ -1785,7 +1789,6 @@
</span>
</div> -->
<div
v-if="cardItem.batchArrangeNumber"
class="grid-item"
......@@ -2338,6 +2341,7 @@ import {
completeDeliveryApi,
get17TrackInfoApi,
getAccountCodeByFactoryIdApi,
printPickPdfByBatchNumberApi,
} from '@/api/podUsOrder'
import { BaseRespData } from '@/types/api'
......@@ -2822,7 +2826,7 @@ const tableColumns = computed(() => {
{
label: '操作',
slot: 'operate',
width: 300,
width: 350,
align: 'center',
fixed: 'right',
prop: 'operate',
......@@ -3536,6 +3540,27 @@ const printPickingOrder = async () => {
loading.close()
}
}
const printPickingOrderItem = async (row: { batchArrangeNum: string }) => {
console.log(333, row)
const loading = ElLoading.service({
fullscreen: true,
text: '操作中...',
background: 'rgba(0, 0, 0, 0.3)',
})
try {
const res = await printPickPdfByBatchNumberApi({
batchArrangeNumber: row.batchArrangeNum,
})
if (res.code !== 200) return
ElMessage.success('操作成功')
window.open(filePath + res.message)
} catch (e) {
console.error(e)
} finally {
loading.close()
}
}
const pickingComplete = async () => {
if (cardSelection.value.length === 0) {
return ElMessage.warning('请选择数据')
......@@ -4118,7 +4143,7 @@ const changeWaySubmit = async (title: string) => {
try {
const params = {
updateByIdParam: {
id: currentItem.value?.id,
id: currentItem.value?.id as number,
dataVersion: currentItem.value?.version as number,
},
logisticsTrialCalculation: { ...changeWayRow.value },
......
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