Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
eshiled-new
/
ne-shield-trialdrive-admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit feb3650d
authored
Jun 27, 2022
by
levphon
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
导出excel下载 安全域名问题修复
1 parent
3d94ec6a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
src/main/java/cn/com/glsx/admin/modules/controller/AbstractController.java
src/main/java/cn/com/glsx/admin/modules/controller/AbstractController.java
View file @
feb3650
...
...
@@ -20,7 +20,7 @@ public class AbstractController {
EasyExcelUtils
.
writeExcel
(
baos
,
dataList
,
fileName
,
clazz
);
//将文件写入内存流 然后上传到文件服务器 返回文件服务器的地址给前端 前端执行下载
FileUploadServerData
uploadServerData
=
FileUploadUtil
.
uploadToFileSystem
(
fileName
,
baos
.
toByteArray
(),
FileConstants
.
EXCEL_TYPE_XLSX
);
return
uploadServerData
.
getUrl
();
return
uploadServerData
.
get
Secure
Url
();
}
catch
(
IOException
e
)
{
log
.
error
(
"上传Excel失败:{}"
,
e
.
getMessage
());
}
...
...
Write
Preview
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