Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
Project
Project
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
fangxinjiang
yifu-mvp
Commits
fb33c4da
Commit
fb33c4da
authored
Jul 27, 2023
by
huyuchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
消息提醒修改
parent
39519a70
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
82 additions
and
63 deletions
+82
-63
TDispatchInfoServiceImpl.java
...v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
+82
-63
No files found.
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
View file @
fb33c4da
...
@@ -5166,7 +5166,12 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5166,7 +5166,12 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
}
}
else
{
}
else
{
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
excelWriter
.
write
(
list
,
writeSheet
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable0
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable1
);
// 第二次写如也会创建头,然后在第一次的后面写入数据
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable2
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable3
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable4
);
}
}
//派减的数据
//派减的数据
searchVo
.
setType
(
CommonConstants
.
ONE_STRING
);
searchVo
.
setType
(
CommonConstants
.
ONE_STRING
);
...
@@ -5196,7 +5201,12 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5196,7 +5201,12 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
}
}
else
{
}
else
{
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
excelWriter
.
write
(
list
,
writeSheet
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable0
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable1
);
// 第二次写如也会创建头,然后在第一次的后面写入数据
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable2
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable3
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable4
);
}
}
if
(
excelWriter
!=
null
)
{
if
(
excelWriter
!=
null
)
{
excelWriter
.
finish
();
excelWriter
.
finish
();
...
@@ -5234,20 +5244,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5234,20 +5244,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
//派增的数据
//派增的数据
searchVo
.
setType
(
CommonConstants
.
ZERO_STRING
);
searchVo
.
setType
(
CommonConstants
.
ZERO_STRING
);
long
count
=
getSocialPersionDisCount
(
searchVo
);
long
count
=
getSocialPersionDisCount
(
searchVo
);
if
(
count
>
CommonConstants
.
ZERO_INT
){
list
=
getSocialPersionDisRecord
(
searchVo
);
if
(
Common
.
isNotNull
(
list
))
{
//判断list的大小是否大于10
if
(
list
.
size
()
<
10
)
{
int
size
=
10
-
list
.
size
();
int
num
=
list
.
size
()
+
1
;
for
(
int
i
=
1
;
i
<=
size
;
i
++)
{
vo
=
new
TDispatchSocialPersionExportVo
();
vo
.
setNum
(
num
);
num
++;
list
.
add
(
vo
);
}
}
List
<
Integer
>
columnIndexes
=
Arrays
.
asList
(
0
,
17
);
List
<
Integer
>
columnIndexes
=
Arrays
.
asList
(
0
,
17
);
CustomCellStyleStrategy
customCellStyleStrategy
=
new
CustomCellStyleStrategy
(
columnIndexes
);
CustomCellStyleStrategy
customCellStyleStrategy
=
new
CustomCellStyleStrategy
(
columnIndexes
);
CustomCellStyleOneStrategy
customCellStyleStrategyOne
=
new
CustomCellStyleOneStrategy
(
columnIndexes
);
CustomCellStyleOneStrategy
customCellStyleStrategyOne
=
new
CustomCellStyleOneStrategy
(
columnIndexes
);
...
@@ -5280,6 +5277,20 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5280,6 +5277,20 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
registerWriteHandler
(
customCellStyleStrategyTwo
).
registerWriteHandler
(
customCellStyleStrategyTwo
).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
20
,(
short
)
20
))
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
20
,(
short
)
20
))
.
build
();
.
build
();
if
(
count
>
CommonConstants
.
ZERO_INT
){
list
=
getSocialPersionDisRecord
(
searchVo
);
if
(
Common
.
isNotNull
(
list
))
{
//判断list的大小是否大于10
if
(
list
.
size
()
<
10
)
{
int
size
=
10
-
list
.
size
();
int
num
=
list
.
size
()
+
1
;
for
(
int
i
=
1
;
i
<=
size
;
i
++)
{
vo
=
new
TDispatchSocialPersionExportVo
();
vo
.
setNum
(
num
);
num
++;
list
.
add
(
vo
);
}
}
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
// 第一次写入会创建头
// 第一次写入会创建头
// 第二次写如也会创建头,然后在第一次的后面写入数据
// 第二次写如也会创建头,然后在第一次的后面写入数据
...
@@ -5291,54 +5302,59 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5291,54 +5302,59 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
}
}
else
{
}
else
{
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"增员"
).
build
();
excelWriter
.
write
(
list
,
writeSheet
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable0
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable1
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable2
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable3
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable4
);
}
}
//派减的数据
//派减的数据
searchVo
.
setType
(
CommonConstants
.
ONE_STRING
);
searchVo
.
setType
(
CommonConstants
.
ONE_STRING
);
long
count1
=
getSocialPersionReduceDisCount
(
searchVo
);
long
count1
=
getSocialPersionReduceDisCount
(
searchVo
);
//获取要导出的列表
//获取要导出的列表
List
<
TDispatchSocialPersionReduceExportVo
>
listReduce
=
new
ArrayList
<>();
List
<
TDispatchSocialPersionReduceExportVo
>
listReduce
=
new
ArrayList
<>();
if
(
count1
>
CommonConstants
.
ZERO_INT
){
listReduce
=
getSocialPersionReduceDisRecord
(
searchVo
);
List
<
Integer
>
columnIndex
=
Arrays
.
asList
(
0
,
23
);
if
(
Common
.
isNotNull
(
listReduce
))
{
CustomCellStyleStrategy
customCellStyleStrategy1
=
new
CustomCellStyleStrategy
(
columnIndex
);
//判断list的大小是否大于10
CustomCellStyleOneStrategy
customCellStyleStrategy2
=
new
CustomCellStyleOneStrategy
(
columnIndex
);
if
(
listReduce
.
size
()
<
10
)
{
CustomCellStyleTwoStrategy
customCellStyleStrategy3
=
new
CustomCellStyleTwoStrategy
(
columnIndex
);
int
size
=
10
-
listReduce
.
size
();
CustomCellStyleThreeStrategy
customCellStyleStrategy4
=
new
CustomCellStyleThreeStrategy
(
columnIndex
);
int
num
=
listReduce
.
size
()
+
1
;
for
(
int
i
=
1
;
i
<=
size
;
i
++)
{
reduceVo
=
new
TDispatchSocialPersionReduceExportVo
();
reduceVo
.
setNum
(
num
);
num
++;
listReduce
.
add
(
reduceVo
);
}
}
List
<
Integer
>
columnIndexes
=
Arrays
.
asList
(
0
,
23
);
CustomCellStyleStrategy
customCellStyleStrategy
=
new
CustomCellStyleStrategy
(
columnIndexes
);
CustomCellStyleOneStrategy
customCellStyleStrategyOne
=
new
CustomCellStyleOneStrategy
(
columnIndexes
);
CustomCellStyleTwoStrategy
customCellStyleStrategyTwo
=
new
CustomCellStyleTwoStrategy
(
columnIndexes
);
CustomCellStyleThreeStrategy
customCellStyleStrategyThree
=
new
CustomCellStyleThreeStrategy
(
columnIndexes
);
writeTable0
=
EasyExcel
.
writerTable
(
0
).
writeTable0
=
EasyExcel
.
writerTable
(
0
).
head
(
persionReduceHeadOne
()).
head
(
persionReduceHeadOne
()).
registerWriteHandler
(
customCellStyleStrategy
).
registerWriteHandler
(
customCellStyleStrategy1
).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
40
,(
short
)
20
)).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
40
,(
short
)
20
)).
build
();
build
();
writeTable1
=
EasyExcel
.
writerTable
(
1
).
writeTable1
=
EasyExcel
.
writerTable
(
1
).
head
(
persionReduceHeadTwo
(
searchVo
.
getSocialHouseholdName
(),
searchVo
.
getCustomerNo
())).
head
(
persionReduceHeadTwo
(
searchVo
.
getSocialHouseholdName
(),
searchVo
.
getCustomerNo
())).
registerWriteHandler
(
customCellStyleStrategyOne
).
registerWriteHandler
(
customCellStyleStrategy2
).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
20
,(
short
)
20
)).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
20
,(
short
)
20
)).
build
();
build
();
writeTable2
=
EasyExcel
.
writerTable
(
2
).
writeTable2
=
EasyExcel
.
writerTable
(
2
).
head
(
persionReduceHead
()).
head
(
persionReduceHead
()).
registerWriteHandler
(
customCellStyleStrategyThree
).
registerWriteHandler
(
customCellStyleStrategy4
).
registerWriteHandler
(
new
CustomCellWriteWidthTwoConfig
()).
registerWriteHandler
(
new
CustomCellWriteWidthTwoConfig
()).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
50
,(
short
)
20
))
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
50
,(
short
)
20
))
.
build
();
.
build
();
writeTable3
=
EasyExcel
.
writerTable
(
3
).
writeTable3
=
EasyExcel
.
writerTable
(
3
).
head
(
persionReduceHead1
()).
head
(
persionReduceHead1
()).
registerWriteHandler
(
customCellStyleStrategyTwo
).
registerWriteHandler
(
customCellStyleStrategy3
).
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
40
,(
short
)
20
))
registerWriteHandler
(
new
SimpleRowHeightStyleStrategy
((
short
)
40
,(
short
)
20
))
.
build
();
.
build
();
if
(
count1
>
CommonConstants
.
ZERO_INT
){
listReduce
=
getSocialPersionReduceDisRecord
(
searchVo
);
if
(
Common
.
isNotNull
(
listReduce
))
{
//判断list的大小是否大于10
if
(
listReduce
.
size
()
<
10
)
{
int
size
=
10
-
listReduce
.
size
();
int
num
=
listReduce
.
size
()
+
1
;
for
(
int
i
=
1
;
i
<=
size
;
i
++)
{
reduceVo
=
new
TDispatchSocialPersionReduceExportVo
();
reduceVo
.
setNum
(
num
);
num
++;
listReduce
.
add
(
reduceVo
);
}
}
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
// 第一次写入会创建头
// 第一次写入会创建头
// 第二次写如也会创建头,然后在第一次的后面写入数据
// 第二次写如也会创建头,然后在第一次的后面写入数据
...
@@ -5349,7 +5365,10 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5349,7 +5365,10 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
}
}
else
{
}
else
{
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
writeSheet
=
EasyExcel
.
writerSheet
(
"减员"
).
build
();
excelWriter
.
write
(
listReduce
,
writeSheet
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable0
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable1
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable2
);
excelWriter
.
write
(
new
ArrayList
<>(),
writeSheet
,
writeTable3
);
}
}
if
(
excelWriter
!=
null
)
{
if
(
excelWriter
!=
null
)
{
excelWriter
.
finish
();
excelWriter
.
finish
();
...
...
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