Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ElectricitySheep
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
黄媛媛
ElectricitySheep
Commits
32738dac
You need to sign in or sign up before continuing.
Commit
32738dac
authored
Sep 14, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
c9f04e15
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
35 deletions
+27
-35
App.vue
src/App.vue
+1
-25
billboardList.vue
src/components/tradePavilion/billboardList.vue
+26
-10
No files found.
src/App.vue
View file @
32738dac
...
...
@@ -20,13 +20,13 @@ export default {
if
(
res
.
data
.
data
)
{
localStorage
.
removeItem
(
"fujianTag"
);
clearInterval
(
this
.
timer
);
localStorage
.
setItem
(
"fujianUrl"
,
res
.
data
.
data
);
this
.
$confirm
(
"有下载文件准备完成, 前往下载?"
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"info"
,
}).
then
(()
=>
{
this
.
$router
.
push
(
"/billboardList"
);
this
.
downloadFujian
(
res
.
data
.
data
);
});
}
}
else
{
...
...
@@ -35,30 +35,6 @@ export default {
}
);
},
downloadFujian
(
url
)
{
let
a
=
document
.
createElement
(
"a"
);
a
.
href
=
this
.
domainManager
().
DomainUrl
+
url
;
a
.
download
=
"榜单附件.zip"
;
a
.
click
();
setTimeout
(()
=>
{
this
.
delDownloadMultiplefujian
(
url
);
},
2000
);
},
//删除附件
delDownloadMultiplefujian
(
url
)
{
this
.
apipost
(
"/api/Trade/DelFirstShopEnrollZipExport"
,
{
Url
:
url
,
},
(
res
)
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
}
else
{
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
);
},
},
mounted
()
{
let
tag
=
localStorage
.
getItem
(
"fujianTag"
);
...
...
src/components/tradePavilion/billboardList.vue
View file @
32738dac
...
...
@@ -31,7 +31,7 @@
style=
"float: right; margin-top: -5px; margin-right: 10px"
size=
"small"
type=
"primary"
@
click=
"downloadFujian
(fujianUrl)
"
@
click=
"downloadFujian"
v-if=
"showfujianbtn"
>
下载附件
</el-button>
...
...
@@ -544,14 +544,18 @@ export default {
(
res
)
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
res
.
data
.
data
)
{
this
.
fujianLoading
=
false
;
this
.
fujianText
=
"榜单附件导出"
;
this
.
fujianText
=
"附件准备完成"
;
localStorage
.
removeItem
(
"fujianTag"
);
clearInterval
(
this
.
timer
);
this
.
fujianUrl
=
res
.
data
.
data
;
localStorage
.
setItem
(
"fujianUrl"
,
res
.
data
.
data
);
this
.
fujianUrl
=
res
.
data
.
data
;
this
.
showfujianbtn
=
true
;
if
(
this
.
$route
.
path
==
"/billboardList"
)
{
this
.
downloadFujian
(
res
.
data
.
data
);
this
.
$alert
(
"下载文件准备完成"
,
{
confirmButtonText
:
"确定"
,
callback
:
(
action
)
=>
{},
});
}
else
{
this
.
$confirm
(
"有下载文件准备完成, 前往下载?"
,
"提示"
,
{
confirmButtonText
:
"确定"
,
...
...
@@ -559,7 +563,7 @@ export default {
type
:
"info"
,
}).
then
(()
=>
{
this
.
$router
.
push
(
"/billboardList"
);
this
.
downloadFujian
(
this
.
fujianUrl
);
//
this.downloadFujian(this.fujianUrl);
});
}
}
...
...
@@ -569,14 +573,15 @@ export default {
}
);
},
downloadFujian
(
url
)
{
downloadFujian
()
{
let
url
=
localStorage
.
getItem
(
"fujianUrl"
);
let
a
=
document
.
createElement
(
"a"
);
a
.
href
=
this
.
domainManager
().
DomainUrl
+
url
;
a
.
href
=
this
.
domainManager
().
DomainUrl
+
"/"
+
url
;
a
.
download
=
"榜单附件.zip"
;
a
.
click
();
setTimeout
(()
=>
{
this
.
delDownloadMultiplefujian
(
url
);
},
2
000
);
},
10
000
);
},
//删除附件
delDownloadMultiplefujian
(
url
)
{
...
...
@@ -587,6 +592,10 @@ export default {
},
(
res
)
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
localStorage
.
removeItem
(
"fujianUrl"
);
this
.
fujianLoading
=
false
;
this
.
fujianText
=
"榜单附件导出"
;
this
.
showfujianbtn
=
false
;
}
else
{
this
.
$message
.
error
(
res
.
data
.
message
);
}
...
...
@@ -594,7 +603,14 @@ export default {
);
},
},
mounted
()
{},
mounted
()
{
let
url
=
localStorage
.
getItem
(
"fujianUrl"
);
if
(
url
)
{
this
.
fujianLoading
=
true
;
this
.
fujianText
=
"附件准备完成"
;
this
.
showfujianbtn
=
true
;
}
},
};
</
script
>
<
style
>
...
...
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