Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
杨炀
/
dance-pc
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
a99d479f
authored
2025-07-22 16:45:05 +0800
by
李婷婷
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
下载文案
1 parent
fbc9968c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
18 deletions
src/utils/request.js
src/views/download/index.vue
src/utils/request.js
View file @
a99d479
...
...
@@ -202,7 +202,7 @@ service.interceptors.response.use(
// 通用下载方法
export
function
download
(
url
,
params
,
filename
,
config
)
{
downloadLoadingInstance
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
service
...
...
src/views/download/index.vue
View file @
a99d479
...
...
@@ -26,6 +26,8 @@ import {
}
from
'@/api/download.js'
import
url
from
'@/assets/images/download.png'
import
{
ElLoading
}
from
'element-plus'
import
{
useStorage
}
from
"@vueuse/core/index"
;
const
language
=
useStorage
(
'language'
,
0
)
const
{
proxy
}
=
getCurrentInstance
()
const
route
=
useRoute
()
const
timer
=
ref
(
null
)
...
...
@@ -36,13 +38,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'batchMember'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downloadPersonCert
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -54,13 +56,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'batchMemberFeeBill'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downJiaoFei
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -72,13 +74,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'batchGroupMemberFeeBill'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downJiaoFeiGroup
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -90,13 +92,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'examCert'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downExamCerts
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -106,13 +108,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'examCertByExamIds'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downExamCertsByExamId
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -122,13 +124,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'examCertByStudentIds'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downExamCertsByStudentId
(
route
.
query
.
arr
,
route
.
query
.
examIds
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
&&
res
.
data
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -140,13 +142,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'batchGroupMember'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downloadPersonCertGroup
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -158,13 +160,13 @@ onMounted(() => {
if
(
route
.
query
.
type
==
'examPayment'
)
{
clearInterval
(
timer
.
value
)
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
return
downExamPayment
(
route
.
query
.
arr
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
&&
res
.
data
)
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
circulation
(
res
.
data
)
...
...
@@ -178,7 +180,7 @@ onMounted(() => {
function
circulation
(
id
)
{
timer
.
value
=
setInterval
(
async
()
=>
{
downloadLoadingInstance
.
value
=
ElLoading
.
service
({
text
:
'正在下载数据,请稍候'
,
text
:
language
==
1
?
'Data is being downloaded. Please wait a moment.'
:
'正在下载数据,请稍候'
,
background
:
'rgba(0, 0, 0, 0.7)'
})
const
res
=
await
queryProcess
(
id
)
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment