Browse Source

YT-421、YT-421预生产收货申请、预生产收货任务导出

intex_online20241111
zhaoyiran 1 month ago
parent
commit
043e11131a
  1. 16
      src/api/wms/productreceiptJobMain/index.ts
  2. 10
      src/api/wms/productreceiptRequestMain/index.ts
  3. 3
      src/views/wms/productionManage/productreceipt/productreceiptJobMain/index.vue
  4. 3
      src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue

16
src/api/wms/productreceiptJobMain/index.ts

@ -116,6 +116,22 @@ export const exportProductreceiptJobMain = async (params) => {
} }
} }
export const exportProductreceiptJobMainPredict = async (params) => {
params.type = 'predict'
if (params.isSearch) {
const cmd = {
'column':'type',
'action':'==',
'value':'predict'
}
params.filters.push(cmd)
const data = {...params}
return await request.downloadPost({ url: `/wms/productreceipt-job-main/export-excel-senior`, data })
} else {
return await request.download({ url: `/wms/productreceipt-job-main/export-excel`, params })
}
}
// 导出装配收货任务主 Excel // 导出装配收货任务主 Excel
export const exportProductreceiptJobMainAssemble = async (params) => { export const exportProductreceiptJobMainAssemble = async (params) => {

10
src/api/wms/productreceiptRequestMain/index.ts

@ -93,6 +93,16 @@ export const exportProductreceiptRequestMain = async (params) => {
} }
} }
export const exportProductreceiptRequestMainPredict = async (params) => {
params.type = 'predict'
if (params.isSearch) {
const data = {...params}
return await request.downloadPost({ url: `/wms/productreceipt-request-main/export-excel-senior`, data })
} else {
return await request.download({ url: `/wms/productreceipt-request-main/export-excel`, params })
}
}
// 导出制品收货申请主 Excel // 导出制品收货申请主 Excel
export const exportProductreceiptRequestMainAssemble = async (params) => { export const exportProductreceiptRequestMainAssemble = async (params) => {
params.type = 'assemble' params.type = 'assemble'

3
src/views/wms/productionManage/productreceipt/productreceiptJobMain/index.vue

@ -106,6 +106,7 @@ import {
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import {exportProductreceiptJobMainPredict} from "@/api/wms/productreceiptJobMain";
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
// //
@ -352,7 +353,7 @@ const handleExport = async () => {
// //
loadStart() loadStart()
const excelTitle = ref(route.meta.title) const excelTitle = ref(route.meta.title)
const data = await ProductreceiptJobMainApi.exportProductreceiptJobMain(tableObject.params) const data = await ProductreceiptJobMainApi.exportProductreceiptJobMainPredict(tableObject.params)
download.excel(data, `${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) download.excel(data, `${excelTitle.value}】【${formatDate(new Date())}】.xlsx`)
} catch { } catch {
} finally { } finally {

3
src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue

@ -189,6 +189,7 @@ import { formatDate } from '@/utils/formatTime'
import * as WorkshopApi from '@/api/wms/workshop' import * as WorkshopApi from '@/api/wms/workshop'
import * as ConfigApi from '@/api/infra/config' import * as ConfigApi from '@/api/infra/config'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import {exportProductreceiptRequestMainPredict} from "@/api/wms/productreceiptRequestMain";
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
// //
@ -687,7 +688,7 @@ const handleExport = async () => {
// //
loadStart() loadStart()
const excelTitle = ref(route.meta.title) const excelTitle = ref(route.meta.title)
const data = await ProductreceiptRequestMainApi.exportProductreceiptRequestMain( const data = await ProductreceiptRequestMainApi.exportProductreceiptRequestMainPredict(
tableObject.params tableObject.params
) )
download.excel(data, `${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) download.excel(data, `${excelTitle.value}】【${formatDate(new Date())}】.xlsx`)

Loading…
Cancel
Save