Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-operator-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-app-operator-master
Commits
13fecbad
Commit
13fecbad
authored
Sep 03, 2023
by
zhoutong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【生产反馈】性能优化:导出预装单时间很久,最快也要一分钟多
parent
1dae0c33
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
13 deletions
+43
-13
indexAir.vue
src/views/ecw/box/indexAir.vue
+21
-6
indexSea.vue
src/views/ecw/box/indexSea.vue
+22
-7
No files found.
src/views/ecw/box/indexAir.vue
View file @
13fecbad
...
...
@@ -506,12 +506,13 @@ export default {
this
.
$router
.
push
(
'
/boxAir/batch_markup?shipmentId=
'
+
row
.
id
)
break
case
"
downloadPreloadGoodsList
"
:
downloadFile
(
command
,
{
shipmentId
:
row
.
id
}
,
this
.
$t
(
"
预装单
"
)
+
`(${row.selfNo
}
).xlsx`
,
"
xlsx
"
);
// downloadFile(
// command,
//
{
shipmentId
:
row
.
id
}
,
// this.$t("预装单") + `($
{
row
.
selfNo
}
).
xlsx
`,
// "xlsx"
// );
this.exportExcel(exportboxExcel, { shipmentId: row.id
}
, this.$t("预装单") + `
(
$
{
row
.
selfNo
}
).
xlsx
`)
break;
case "downloadLoadGoodsList":
downloadFile(
...
...
@@ -563,6 +564,20 @@ export default {
this.$set(this.dialogCfg, "open", true);
}
}
,
// 通用导出函数
exportExcel(func, params, fileName = null){
this.exportLoading = true;
func(params).then(res => {
console.log({res
}
)
if(!fileName){
fileName = this.$t('订单')
}
this.$message.success(this.$t('已加入导出队列,请稍后在下载日志中下载'))
// this.$download.excel(res, fileName + '.xls');
}
).finally(() => {
this.exportLoading = false
}
)
}
,
}
}
...
...
src/views/ecw/box/indexSea.vue
View file @
13fecbad
...
...
@@ -287,7 +287,7 @@ export default {
countryList
:
[],
// 通知列表
noticeList
:
[],
allUsers
:
[]
,
allUsers
:
[]
}
;
}
,
computed
:
{
...
...
@@ -489,12 +489,13 @@ export default {
break
;
case
"
downloadPreloadGoodsList
"
:
downloadFile
(
command
,
{
shipmentId
:
row
.
id
}
,
this
.
$t
(
"
预装单
"
)
+
`(${row.selfNo
}
).xlsx`
,
"
xlsx
"
);
// downloadFile(
// command,
//
{
shipmentId
:
row
.
id
}
,
// this.$t("预装单") + `($
{
row
.
selfNo
}
).
xlsx
`,
// "xlsx"
// );
this.exportExcel(exportboxExcel, { shipmentId: row.id
}
, this.$t("预装单") + `
(
$
{
row
.
selfNo
}
).
xlsx
`)
break;
case "downloadLoadGoodsList":
downloadFile(
...
...
@@ -547,6 +548,20 @@ export default {
this.$set(this.dialogCfg, "open", true);
}
}
,
// 通用导出函数
exportExcel(func, params, fileName = null){
this.exportLoading = true;
func(params).then(res => {
console.log({res
}
)
if(!fileName){
fileName = this.$t('订单')
}
this.$message.success(this.$t('已加入导出队列,请稍后在下载日志中下载'))
// this.$download.excel(res, fileName + '.xls');
}
).finally(() => {
this.exportLoading = false
}
)
}
,
/* 分页 */
pageChange(page) {
this.pageParam.page = page;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment