|
|
@ -87,6 +87,7 @@ import * as CountJobDetailApi from '@/api/wms/countJobDetail' |
|
|
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
|
|
|
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' |
|
|
|
import * as PackageunitApi from "@/api/wms/packageunit"; |
|
|
|
import { formatDate } from '@/utils/formatTime' |
|
|
|
// 盘点任务主 |
|
|
|
defineOptions({ name: 'CountJobMain' }) |
|
|
|
|
|
|
@ -307,8 +308,9 @@ const handleExport = async () => { |
|
|
|
await message.exportConfirm() |
|
|
|
// 发起导出 |
|
|
|
exportLoading.value = true |
|
|
|
const excelTitle = ref(route.meta.title) |
|
|
|
const data = await CountJobMainApi.exportCountJobMain(tableObject.params) |
|
|
|
download.excel(data, '盘点任务主.xlsx') |
|
|
|
download.excel(data, `【${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) |
|
|
|
} catch { |
|
|
|
} finally { |
|
|
|
exportLoading.value = false |
|
|
@ -320,8 +322,10 @@ const handleExportCountJob = async (id: number,number: string) => { |
|
|
|
try { |
|
|
|
await message.exportConfirm() |
|
|
|
exportLoading.value = true |
|
|
|
const excelTitle = ref(route.meta.title) |
|
|
|
const data = await CountJobMainApi.handleExportCountJob(id) |
|
|
|
download.excel(data, '盘点任务主'+number+'.xlsx') |
|
|
|
// download.excel(data, '盘点任务主'+number+'.xlsx') |
|
|
|
download.excel(data, `【${excelTitle.value}${number}】【${formatDate(new Date())}】.xlsx`) |
|
|
|
} catch { |
|
|
|
}finally { |
|
|
|
exportLoading.value = false |
|
|
@ -339,7 +343,7 @@ const handleImport = (id: string) => { |
|
|
|
// 导入附件弹窗所需的参数 |
|
|
|
const importTemplateData = reactive({ |
|
|
|
templateUrl: '', |
|
|
|
templateTitle: '盘点任务导入模版.xlsx' |
|
|
|
templateTitle: `【${route.meta.title}】导入模版.xlsx` |
|
|
|
}) |
|
|
|
|
|
|
|
// 导入成功之后 |
|
|
|