Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-platform
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
youjj
cloud-platform
Commits
a0c03fec
Commit
a0c03fec
authored
Dec 02, 2020
by
周健威
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改保险
parent
c639ac78
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
6 deletions
+15
-6
CommonBaseController.java
...ub/wxiaoqi/security/common/rest/CommonBaseController.java
+6
-6
PgOrderPersonInsuranceController.java
...der/rest/background/PgOrderPersonInsuranceController.java
+1
-0
OrderPersonInsuranceMapper.xml
.../src/main/resources/mapper/OrderPersonInsuranceMapper.xml
+8
-0
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/rest/CommonBaseController.java
View file @
a0c03fec
...
...
@@ -61,11 +61,11 @@ public class CommonBaseController {
}
}
public
void
export
(
Logger
log
,
Map
<
String
,
Object
>
headerAlias
,
Supplier
<
List
<
Map
>>
function
,
String
titl
e
)
throws
Exception
{
public
void
export
(
Logger
log
,
Map
<
String
,
Object
>
headerAlias
,
Supplier
<
List
<
Map
>>
function
,
String
fileNam
e
)
throws
Exception
{
HttpServletResponse
httpServletResponse
=
getResponse
();
ExcelWriter
writer
=
ExcelUtil
.
getWriter
(
true
);
if
(
StrUtil
.
isBlank
(
titl
e
))
{
titl
e
=
System
.
currentTimeMillis
()+
""
;
if
(
StrUtil
.
isBlank
(
fileNam
e
))
{
fileNam
e
=
System
.
currentTimeMillis
()+
""
;
}
try
{
...
...
@@ -89,7 +89,7 @@ public class CommonBaseController {
log
.
info
(
"list: {} "
,
JSONUtil
.
toJsonStr
(
list
));
writer
.
write
(
list
);
httpServletResponse
.
setContentType
(
"application/octet-stream;charset=utf-8"
);
httpServletResponse
.
setHeader
(
"Content-Disposition"
,
"attachment;filename="
+
URLEncoder
.
encode
(
titl
e
+
".xlsx"
,
"utf-8"
));
httpServletResponse
.
setHeader
(
"Content-Disposition"
,
"attachment;filename="
+
URLEncoder
.
encode
(
fileNam
e
+
".xlsx"
,
"utf-8"
));
writer
.
flush
(
httpServletResponse
.
getOutputStream
());
}
catch
(
Exception
ex
)
{
log
.
error
(
ex
.
getMessage
(),
ex
);
...
...
@@ -99,10 +99,10 @@ public class CommonBaseController {
}
}
public
<
T
>
void
exportBean
(
Logger
log
,
T
headerAlias
,
Supplier
<
List
<
Map
>>
function
,
String
titl
e
)
throws
Exception
{
public
<
T
>
void
exportBean
(
Logger
log
,
T
headerAlias
,
Supplier
<
List
<
Map
>>
function
,
String
fileNam
e
)
throws
Exception
{
export
(
log
,
BeanUtil
.
beanToMap
(
headerAlias
),
()->
function
.
get
()
,
titl
e
);
,
fileNam
e
);
}
}
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/rest/background/PgOrderPersonInsuranceController.java
View file @
a0c03fec
...
...
@@ -68,6 +68,7 @@ public class PgOrderPersonInsuranceController extends BaseController<OrderPerson
List
<
OrderPersonInsurance
>
bgList
=
baseBiz
.
selectInsuranceInfo
(
dto
);
List
<
Map
>
list
=
CollUtil
.
newArrayList
();
bgList
.
forEach
(
vo
->
{
//OrderNo Name IdCard
PageExportDTO
ped
=
BeanUtil
.
toBean
(
vo
,
PageExportDTO
.
class
);
switch
(
vo
.
getStatus
())
{
case
OrderPersonInsurance
.
STATUS_PAY
:
...
...
xx-order/xx-order-server/src/main/resources/mapper/OrderPersonInsuranceMapper.xml
View file @
a0c03fec
...
...
@@ -21,12 +21,20 @@
<select
id=
"selectOrderInfo"
resultType=
"com.xxfc.platform.order.pojo.personinsurance.BgPageVO"
>
select distinct ob.no, ob.insure_pic
<include
refid=
"commonFromWhere"
></include>
order by
ob.no desc
</select>
<select
id=
"selectInsuranceInfo"
resultType=
"com.xxfc.platform.order.entity.OrderPersonInsurance"
>
select opi.*
<include
refid=
"commonFromWhere"
></include>
order by
ob.no desc
</select>
<sql
id=
"commonFromWhere"
>
...
...
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