|
@@ -715,16 +715,32 @@ async function exportZip() {
|
|
|
if (!currentMonth.value) return;
|
|
if (!currentMonth.value) return;
|
|
|
|
|
|
|
|
isLoadingZip.value = true;
|
|
isLoadingZip.value = true;
|
|
|
|
|
+ let path = "";
|
|
|
|
|
+ let type = "";
|
|
|
|
|
+ switch (exportModalTitle.value) {
|
|
|
|
|
+ case "航次列表": {
|
|
|
|
|
+ path = "/voyage/exportListExcel";
|
|
|
|
|
+ type =
|
|
|
|
|
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8";
|
|
|
|
|
+ break;
|
|
|
|
|
+ }
|
|
|
|
|
+ case "航次跟踪": {
|
|
|
|
|
+ path = "/voyage/exportMultExcel";
|
|
|
|
|
+ type = "application/zip";
|
|
|
|
|
+ break;
|
|
|
|
|
+ }
|
|
|
|
|
+ case "卸货记录": {
|
|
|
|
|
+ path = "/voyage/exportMultDischargeExcel";
|
|
|
|
|
+ type = "application/zip";
|
|
|
|
|
+ break;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
let res = await downloadBlobFile(
|
|
let res = await downloadBlobFile(
|
|
|
- `${url.baseurl}${
|
|
|
|
|
- exportModalTitle.value == "卸货记录"
|
|
|
|
|
- ? "/voyage/exportMultDischargeExcel"
|
|
|
|
|
- : "/voyage/exportMultExcel"
|
|
|
|
|
- }`,
|
|
|
|
|
|
|
+ `${url.baseurl}${path}`,
|
|
|
{ loginAccountId: localStorage.loginAccountId, date: currentMonth.value },
|
|
{ loginAccountId: localStorage.loginAccountId, date: currentMonth.value },
|
|
|
`${exportModalTitle.value}${currentMonth.value}`,
|
|
`${exportModalTitle.value}${currentMonth.value}`,
|
|
|
"post",
|
|
"post",
|
|
|
- "application/zip"
|
|
|
|
|
|
|
+ type
|
|
|
);
|
|
);
|
|
|
ElNotification({
|
|
ElNotification({
|
|
|
title: "导出成功!",
|
|
title: "导出成功!",
|