Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-platform-auth
Overview
Overview
Details
Activity
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
base_platform_enterprise
gic-platform-auth
Commits
cd7dc451
Commit
cd7dc451
authored
Sep 18, 2020
by
guojuxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pmd
parent
bd1b4552
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 additions
and
93 deletions
+1
-93
CollaboratorController.java
...a/com/gic/auth/web/controller/CollaboratorController.java
+1
-46
TestObj.java
...m-auth-web/src/main/java/com/gic/auth/web/vo/TestObj.java
+0
-47
No files found.
gic-platform-auth-web/src/main/java/com/gic/auth/web/controller/CollaboratorController.java
View file @
cd7dc451
...
...
@@ -12,7 +12,6 @@ import com.gic.auth.qo.MenuListQO;
import
com.gic.auth.service.CollaboratorApiService
;
import
com.gic.auth.service.MenuApiService
;
import
com.gic.auth.web.vo.CollaboratorDetailVO
;
import
com.gic.auth.web.vo.TestObj
;
import
com.gic.commons.util.DateUtil
;
import
com.gic.commons.webapi.reponse.RestResponse
;
import
com.gic.download.utils.*
;
...
...
@@ -85,51 +84,7 @@ public class CollaboratorController extends DownloadUtils{
Integer
reportId
=
DataDownloadUtils
.
createDownloadReport
(
report
);
//临时路径
String
path
=
request
.
getSession
().
getServletContext
().
getRealPath
(
"/excel/csv/collaborator/file/"
);
//异步生成文件并上传到腾讯云
ExecutorPoolSingleton
.
getInstance
().
executeTask
(
new
Runnable
()
{
@Override
public
void
run
()
{
List
<
Map
<
String
,
Object
>>
dataList
=
new
ArrayList
<>();
Map
<
String
,
Object
>
map1
=
new
HashMap
<>(
8
);
map1
.
put
(
"test1"
,
"test1"
);
map1
.
put
(
"2"
,
new
TestObj
(
"域名2门店1-1"
,
"域名2门店2-1"
));
map1
.
put
(
"3"
,
new
TestObj
(
"域名3门店1-1"
,
"域名3门店2-1"
));
dataList
.
add
(
map1
);
Map
<
String
,
Object
>
map2
=
new
HashMap
<>(
8
);
map2
.
put
(
"test1"
,
"test2"
);
map2
.
put
(
"2"
,
new
TestObj
(
"域名2门店1-2"
,
"域名2门店2-2"
));
map2
.
put
(
"3"
,
new
TestObj
(
"域名3门店1-2"
,
"域名3门店2-2"
));
dataList
.
add
(
map2
);
DownloadDataLoader
<
Map
<
String
,
Object
>>
loader
=
new
DownloadDataLoader
<
Map
<
String
,
Object
>>()
{
@Override
protected
List
<
Map
<
String
,
Object
>>
getDownloadData
(
Integer
pageNum
)
throws
Exception
{
params
.
setCurrentPage
(
pageNum
);
if
(
PAGE_NUM_TEST
.
equals
(
pageNum
))
{
//第二页结束test
return
null
;
}
return
dataList
;
}
};
LinkedHashMap
<
String
,
List
<
String
>>
headerList
=
new
LinkedHashMap
<>();
headerList
.
put
(
"测试1"
,
null
);
headerList
.
put
(
"域名2"
,
Arrays
.
asList
(
"门店1"
,
"门店2"
));
headerList
.
put
(
"域名3"
,
Arrays
.
asList
(
"门店1"
,
"门店2"
));
LinkedHashMap
<
String
,
List
<
String
>>
propertyNameList
=
new
LinkedHashMap
<>();
propertyNameList
.
put
(
"test1"
,
null
);
propertyNameList
.
put
(
"2"
,
Arrays
.
asList
(
"store1"
,
"store2"
));
propertyNameList
.
put
(
"3"
,
Arrays
.
asList
(
"store1"
,
"store2"
));
Map
<
String
,
List
<
String
>>
needEncryptField
=
new
HashMap
<>(
16
);
needEncryptField
.
put
(
"test1"
,
null
);
needEncryptField
.
put
(
"2"
,
Arrays
.
asList
(
"store1"
));
needEncryptField
.
put
(
"3"
,
Arrays
.
asList
(
"store2"
));
try
{
downloadForDoubleHeaderTitle
(
path
,
reportId
,
fileName
,
excelExtensionCode
,
headerList
,
propertyNameList
,
loader
,
needEncryptField
,
null
);
}
catch
(
Exception
e
)
{
LOGGER
.
warn
(
e
);
}
}
});
return
RestResponse
.
success
(
reportId
);
}
...
...
gic-platform-auth-web/src/main/java/com/gic/auth/web/vo/TestObj.java
deleted
100644 → 0
View file @
bd1b4552
package
com
.
gic
.
auth
.
web
.
vo
;
import
com.gic.commons.annotation.SkipNamingCheck
;
import
java.io.Serializable
;
/**
*
* @ClassName: TestObj
* @Description:
* @author zhiwj
* @date 2020-09-10 10:03
*/
@SkipNamingCheck
public
class
TestObj
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
4882149987195822359L
;
private
String
store1
;
private
String
store2
;
public
TestObj
()
{
}
public
TestObj
(
String
store1
,
String
store2
)
{
this
.
store1
=
store1
;
this
.
store2
=
store2
;
}
public
String
getStore1
()
{
return
store1
;
}
public
TestObj
setStore1
(
String
store1
)
{
this
.
store1
=
store1
;
return
this
;
}
public
String
getStore2
()
{
return
store2
;
}
public
TestObj
setStore2
(
String
store2
)
{
this
.
store2
=
store2
;
return
this
;
}
}
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