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
5e145b08
Commit
5e145b08
authored
Aug 06, 2024
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
111
parent
a5a9eedf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
10 deletions
+30
-10
brandManagement.vue
src/components/tradePavilion/brandManagement.vue
+30
-10
No files found.
src/components/tradePavilion/brandManagement.vue
View file @
5e145b08
...
...
@@ -323,7 +323,7 @@
if
(
res
.
data
.
resultCode
==
1
)
{
clearInterval
(
this
.
download_timer
);
this
.
checkedCities
=
[];
this
.
loadingText
=
"正在下载品牌文件,请勿关闭或刷新页面..."
;
;
this
.
loadingText
=
"正在下载品牌文件,请勿关闭或刷新页面..."
;
var
fileUrl
=
res
.
data
.
data
.
fileUrl
;
var
filepath
=
res
.
data
.
data
.
filePath
;
var
key
=
res
.
data
.
message
;
...
...
@@ -346,20 +346,40 @@
// linkObj.setAttribute("download", "品牌信息.xls");
// linkObj.click();
that
.
GetLocalFile
(
"/api/Trade/GetFile"
,
params
,
"品牌信息.xls"
,
null
,
()
=>
{
that
.
downLoadLoading
=
false
;
that
.
loadingText
=
""
;
that
.
apipost
(
"/api/Trade/DeleteKey"
,
deleteparams
,
(
res
)
=>
{
})
that
.
dialogVisible
=
false
;
var
apiurl
=
that
.
domainManager
().
DomainUrl
+
"/api/Trade/GetFile"
;
var
postData
=
that
.
GetPostData
(
""
,
params
,
""
);
that
.
$http
.
post
(
apiurl
,
postData
,
{
responseType
:
'arraybuffer'
,
onDownloadProgress
:
(
progressEvent
)
=>
{
const
progress
=
Math
.
round
((
progressEvent
.
loaded
/
progressEvent
.
total
)
*
100
);
that
.
loadingText
=
`正在下载品牌文件`
+
progress
+
`%,请勿关闭或刷新页面...`
;
// 在这里处理下载进度, 如更新界面上的进度条
}
);
}).
then
((
res
)
=>
{
let
blob
=
new
Blob
([
res
.
data
],
{
type
:
"application/vnd.ms-excel"
})
let
url
=
URL
.
createObjectURL
(
blob
);
let
link
=
document
.
createElement
(
'a'
);
link
.
href
=
url
;
link
.
setAttribute
(
"download"
,
fileName
);
document
.
body
.
appendChild
(
link
);
link
.
click
();
that
.
downLoadLoading
=
false
;
that
.
loadingText
=
""
;
that
.
apipost
(
"/api/Trade/DeleteKey"
,
deleteparams
,
(
res
)
=>
{
})
that
.
dialogVisible
=
false
;
}).
catch
(
function
(
res
)
{});
}
}
);
},
getDown
()
{
this
.
cityOptions
=
[];
this
.
apipost
(
"/api/Trade/GetBusinessExportEnumList"
,
{},
(
res
)
=>
{
...
...
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