Commit 7f9a1976 by zhuzhequan

添加排版功能

parent 5cb420f2
......@@ -64,7 +64,7 @@ declare module 'vue' {
ShipmentOrderDetail: typeof import('./src/components/ShipmentOrderDetail.vue')['default']
SplitDiv: typeof import('./src/components/splitDiv/splitDiv.vue')['default']
'Switch ': typeof import('./src/components/Form.vue/Switch .vue')['default']
TableRightClickMenu: typeof import('./src/components/TableRightClickMenu.vue')['default']
TableRightMenu: typeof import('./src/components/TableRightMenu.vue')['default']
TableView: typeof import('./src/components/TableView.vue')['default']
UploadExcel: typeof import('./src/components/UploadExcel.vue')['default']
UploadImage: typeof import('./src/components/UploadImage.vue')['default']
......
......@@ -4,7 +4,7 @@ import { showError } from '@/utils/ui.ts'
const axios = Axios.create({
baseURL: import.meta.env.VITE_API_BASE,
timeout: 30000,
timeout: 300000, //凯哥让改的超时时间
})
const TOKEN_KEY = 'token'
......
......@@ -306,6 +306,16 @@ export function createLogisticsOrderApi(params: {
params,
)
}
// 更改物流
export function composingDesignImages(data:number[]) {
return axios.post<never, BaseRespData<never>>(
'factory/podJomallOrderUs/composingDesignImages',
data,{
responseType: 'blob', // 设置响应类型为 Blob(处理二进制流)
}
)
}
// 转至待拣胚
export function updateLogisticsToPickingApi(params: { ids: string }) {
return axios.get<never, BaseRespData<never>>(
......
......@@ -230,6 +230,9 @@
</div>
</div>
<div class="operation-box mb-10">
<span v-if="status === 'PICKING'" class="item">
<ElButton :loading="downloadLoading" type="primary" @click="downloadTif"> 排版 </ElButton>
</span>
<span v-if="status === 'TO_BE_CONFIRMED'" class="item">
<ElButton type="success" @click="confirmOrder"> 确认 </ElButton>
</span>
......@@ -1218,6 +1221,7 @@ import {
getTrackingNumberApi,
getfaceSimplexFileApi,
cancelLogisticsOrderApi,
composingDesignImages,
changeLogisticsApi,
createLogisticsOrderApi,
updateLogisticsToPickingApi,
......@@ -1270,6 +1274,7 @@ declare global {
const tabsNav = ref<Tab[]>()
const resultRefs = ref<InstanceType<typeof ResultInfo> | null>(null)
const confirmDialogShow = ref(false)
const downloadLoading = ref(false)
const isChangeWay = ref(false)
const confirmData = ref([])
const logisticsWayData = ref([])
......@@ -1598,6 +1603,22 @@ const confirmOrder = async () => {
productionClientValue.value = ''
productionClientVisible.value = true
}
const downloadTif = async () => {
if(!selection.value.length) {
return ElMessage.warning('请选择数据')
}
downloadLoading.value = true
try {
const res= await composingDesignImages(selection.value.map(el=>el.id))
window.open(filePath+res.message, '_blank')
downloadLoading.value = false
}catch (e){
downloadLoading.value = false
}
}
const loadProductionClient = async () => {
try {
const res = await getProductionClientApi()
......
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