Commit 2f4ca57f by zhangxw

导出文件 被拦截替代方式修改

1 parent 1a6ba506
...@@ -76,7 +76,7 @@ import moment from "moment"; ...@@ -76,7 +76,7 @@ import moment from "moment";
import GlsxOrganization from "@/components/glsx-organization"; import GlsxOrganization from "@/components/glsx-organization";
import GlsxTable from "@/components/glsx-table/table"; import GlsxTable from "@/components/glsx-table/table";
import { GET_ALARM_LIST, GET_ALARM_EXPORT } from "@/services/alarmCenter"; import { GET_ALARM_LIST, GET_ALARM_EXPORT } from "@/services/alarmCenter";
import { deepClone, showToast } from "@/utils/util"; import { deepClone, showToast, downFileByPath } from "@/utils/util";
// import { alarmShortcuts } from "@/common" // import { alarmShortcuts } from "@/common"
import qs from 'qs' import qs from 'qs'
export default { export default {
...@@ -188,7 +188,8 @@ export default { ...@@ -188,7 +188,8 @@ export default {
if (res.code != 200) { if (res.code != 200) {
return false; return false;
} }
window.open(res.data); // window.open(res.data);
downFileByPath(res.data)
}); });
}, },
......
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
<script> <script>
import moment from "moment"; import moment from "moment";
import { GET_ALARM_HANDLE_LOG, GET_ALARM_HANDLE_LOG_EXPORT } from "@/services/alarmCenter"; import { GET_ALARM_HANDLE_LOG, GET_ALARM_HANDLE_LOG_EXPORT } from "@/services/alarmCenter";
import { deepClone } from "@/utils/util"; import { deepClone, downFileByPath } from "@/utils/util";
import GlsxOrganization from "@/components/glsx-organization"; import GlsxOrganization from "@/components/glsx-organization";
import { alarmLogShortcuts } from "@/common" import { alarmLogShortcuts } from "@/common"
import GlsxTable from "@/components/glsx-table/table"; import GlsxTable from "@/components/glsx-table/table";
...@@ -168,7 +168,8 @@ export default { ...@@ -168,7 +168,8 @@ export default {
if (res.code != 200) { if (res.code != 200) {
return false; return false;
} }
window.open(res.data); // window.open(res.data);
downFileByPath(res.data)
}); });
}, },
......
...@@ -61,7 +61,7 @@ import { ...@@ -61,7 +61,7 @@ import {
GET_OPEREPORT_VEHICLE_SEARCH, GET_OPEREPORT_VEHICLE_SEARCH,
} from "services/report"; } from "services/report";
import GlsxOrganization from "@/components/glsx-organization"; import GlsxOrganization from "@/components/glsx-organization";
import { deepClone, showToast } from "@/utils/util"; import { deepClone, showToast, downFileByPath } from "@/utils/util";
import GlsxDialog from "@/components/dialog"; import GlsxDialog from "@/components/dialog";
import { staticReportCarShortcuts } from "@/common"; import { staticReportCarShortcuts } from "@/common";
export default { export default {
...@@ -155,7 +155,8 @@ export default { ...@@ -155,7 +155,8 @@ export default {
if (res.code != 200) { if (res.code != 200) {
return false; return false;
} }
window.open(res.data); // window.open(res.data);
downFileByPath(res.data);
}); });
}, },
......
...@@ -61,7 +61,7 @@ import { ...@@ -61,7 +61,7 @@ import {
GET_OPEREPORT_DEVICE_EXPORT, GET_OPEREPORT_DEVICE_EXPORT,
} from "services/report"; } from "services/report";
import GlsxOrganization from "@/components/glsx-organization"; import GlsxOrganization from "@/components/glsx-organization";
import { deepClone, showToast } from "@/utils/util"; import { deepClone, showToast, downFileByPath } from "@/utils/util";
import GlsxDialog from "@/components/dialog"; import GlsxDialog from "@/components/dialog";
import {staticReportCarShortcuts} from '@/common' import {staticReportCarShortcuts} from '@/common'
export default { export default {
...@@ -155,7 +155,8 @@ export default { ...@@ -155,7 +155,8 @@ export default {
if (res.code != 200) { if (res.code != 200) {
return false; return false;
} }
window.open(res.data); // window.open(res.data);
downFileByPath(res.data)
}); });
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!