Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
midjourney-proxy
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
徐少华
midjourney-proxy
Commits
6b0168ec
Commit
6b0168ec
authored
Sep 29, 2022
by
吴博
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/1008584' into 'release'
Feature/1008584 See merge request rays/pcloud-book!1688
parents
0f9a8b33
33b9787e
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
126 additions
and
11 deletions
+126
-11
BookBiz.java
...-book/src/main/java/com/pcloud/book/book/biz/BookBiz.java
+1
-1
BookBizImpl.java
.../main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
+78
-4
BookDaoImpl.java
.../main/java/com/pcloud/book/book/dao/impl/BookDaoImpl.java
+1
-1
BookFacade.java
...src/main/java/com/pcloud/book/book/facade/BookFacade.java
+1
-0
BookFacadeImpl.java
...java/com/pcloud/book/book/facade/impl/BookFacadeImpl.java
+2
-1
BookSet.java
...-book/src/main/java/com/pcloud/book/book/set/BookSet.java
+3
-3
ExportConsr.java
...ain/java/com/pcloud/book/consumer/common/ExportConsr.java
+17
-0
BookConsr.java
...n/java/com/pcloud/book/consumer/settlement/BookConsr.java
+11
-0
BookProps.java
.../main/java/com/pcloud/book/util/properties/BookProps.java
+11
-0
Book.Mapper.xml
...rvice-book/src/main/resources/mapper/book/Book.Mapper.xml
+1
-1
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/book/biz/BookBiz.java
View file @
6b0168ec
...
@@ -583,7 +583,7 @@ public interface BookBiz {
...
@@ -583,7 +583,7 @@ public interface BookBiz {
/**
/**
* 书刊收益列表-出版端
* 书刊收益列表-出版端
*/
*/
PageBeanNew
<
BookSaleVO
>
listPageIncomeDetail
(
PageParam
pageParam
,
Map
<
String
,
Object
>
paramMap
,
Long
agentId
);
PageBeanNew
<
BookSaleVO
>
listPageIncomeDetail
(
PageParam
pageParam
,
Map
<
String
,
Object
>
paramMap
,
Long
agentId
,
String
sortType
);
/**
/**
* 时代大屏用
* 时代大屏用
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
View file @
6b0168ec
...
@@ -8,6 +8,8 @@ import cn.hutool.core.collection.CollUtil;
...
@@ -8,6 +8,8 @@ import cn.hutool.core.collection.CollUtil;
import
cn.hutool.core.date.DateUtil
;
import
cn.hutool.core.date.DateUtil
;
import
cn.hutool.core.map.MapUtil
;
import
cn.hutool.core.map.MapUtil
;
import
cn.hutool.core.util.StrUtil
;
import
cn.hutool.core.util.StrUtil
;
import
cn.hutool.json.JSONUtil
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.google.common.collect.Lists
;
import
com.google.common.collect.Lists
;
import
com.google.common.collect.Maps
;
import
com.google.common.collect.Maps
;
...
@@ -127,6 +129,7 @@ import com.pcloud.book.consumer.message.MessageConsr;
...
@@ -127,6 +129,7 @@ import com.pcloud.book.consumer.message.MessageConsr;
import
com.pcloud.book.consumer.raystask.AdviserTaskConsr
;
import
com.pcloud.book.consumer.raystask.AdviserTaskConsr
;
import
com.pcloud.book.consumer.raystask.MainLineConsr
;
import
com.pcloud.book.consumer.raystask.MainLineConsr
;
import
com.pcloud.book.consumer.resource.ProductConsr
;
import
com.pcloud.book.consumer.resource.ProductConsr
;
import
com.pcloud.book.consumer.settlement.BookConsr
;
import
com.pcloud.book.consumer.trade.TradeConsr
;
import
com.pcloud.book.consumer.trade.TradeConsr
;
import
com.pcloud.book.consumer.user.AdviserConsr
;
import
com.pcloud.book.consumer.user.AdviserConsr
;
import
com.pcloud.book.consumer.user.AgentConsr
;
import
com.pcloud.book.consumer.user.AgentConsr
;
...
@@ -160,6 +163,7 @@ import com.pcloud.book.rightsSetting.dao.RightsNowItemDao;
...
@@ -160,6 +163,7 @@ import com.pcloud.book.rightsSetting.dao.RightsNowItemDao;
import
com.pcloud.book.rightsSetting.mapper.RightsSettingBookRelationMapper
;
import
com.pcloud.book.rightsSetting.mapper.RightsSettingBookRelationMapper
;
import
com.pcloud.book.util.common.ThreadPoolUtils
;
import
com.pcloud.book.util.common.ThreadPoolUtils
;
import
com.pcloud.book.util.common.YesOrNoEnums
;
import
com.pcloud.book.util.common.YesOrNoEnums
;
import
com.pcloud.book.util.properties.BookProps
;
import
com.pcloud.channelcenter.catalog.dto.NoviceGuideCreateDTO
;
import
com.pcloud.channelcenter.catalog.dto.NoviceGuideCreateDTO
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeLocationDto
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeLocationDto
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeSceneDto
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeSceneDto
;
...
@@ -187,6 +191,8 @@ import com.pcloud.common.utils.NumberUtil;
...
@@ -187,6 +191,8 @@ import com.pcloud.common.utils.NumberUtil;
import
com.pcloud.common.utils.ResponseHandleUtil
;
import
com.pcloud.common.utils.ResponseHandleUtil
;
import
com.pcloud.common.utils.cache.redis.JedisClusterUtils
;
import
com.pcloud.common.utils.cache.redis.JedisClusterUtils
;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.commoncenter.export.dto.ExportDto
;
import
com.pcloud.commoncenter.export.dto.ExportSheetDto
;
import
com.pcloud.labelcenter.label.service.LabelService
;
import
com.pcloud.labelcenter.label.service.LabelService
;
import
com.pcloud.message.common.enums.YesNoEnums
;
import
com.pcloud.message.common.enums.YesNoEnums
;
import
com.pcloud.resourcecenter.product.dto.ProductDto
;
import
com.pcloud.resourcecenter.product.dto.ProductDto
;
...
@@ -381,6 +387,8 @@ public class BookBizImpl implements BookBiz {
...
@@ -381,6 +387,8 @@ public class BookBizImpl implements BookBiz {
private
NoviceGuideDeleteDao
noviceGuideDeleteDao
;
private
NoviceGuideDeleteDao
noviceGuideDeleteDao
;
@Autowired
@Autowired
private
BookElasticSearchConsr
bookElasticSearchConsr
;
private
BookElasticSearchConsr
bookElasticSearchConsr
;
@Autowired
private
BookConsr
bookConsr
;
/**
/**
* 创建书籍,同时建立与编辑的推广关系
* 创建书籍,同时建立与编辑的推广关系
...
@@ -2295,7 +2303,7 @@ public class BookBizImpl implements BookBiz {
...
@@ -2295,7 +2303,7 @@ public class BookBizImpl implements BookBiz {
@ParamLog
(
"书刊收益列表--出版端"
)
@ParamLog
(
"书刊收益列表--出版端"
)
@Override
@Override
public
PageBeanNew
<
BookSaleVO
>
listPageIncomeDetail
(
PageParam
pageParam
,
Map
<
String
,
Object
>
paramMap
,
Long
agentId
)
{
public
PageBeanNew
<
BookSaleVO
>
listPageIncomeDetail
(
PageParam
pageParam
,
Map
<
String
,
Object
>
paramMap
,
Long
agentId
,
String
sortType
)
{
List
<
Long
>
adviserIds
=
adviserConsr
.
getIdsByNameAndAgentId
(
agentId
,
(
String
)
paramMap
.
get
(
"keyWord"
));
List
<
Long
>
adviserIds
=
adviserConsr
.
getIdsByNameAndAgentId
(
agentId
,
(
String
)
paramMap
.
get
(
"keyWord"
));
List
<
Long
>
agent4AdviserIds
=
adviserConsr
.
getIdsByNameAndAgentId
(
agentId
,
null
);
List
<
Long
>
agent4AdviserIds
=
adviserConsr
.
getIdsByNameAndAgentId
(
agentId
,
null
);
paramMap
.
put
(
"adviserIds"
,
adviserIds
);
paramMap
.
put
(
"adviserIds"
,
adviserIds
);
...
@@ -2303,12 +2311,53 @@ public class BookBizImpl implements BookBiz {
...
@@ -2303,12 +2311,53 @@ public class BookBizImpl implements BookBiz {
if
(
ListUtils
.
isEmpty
(
agent4AdviserIds
))
{
if
(
ListUtils
.
isEmpty
(
agent4AdviserIds
))
{
return
new
PageBeanNew
<>(
0
,
0
,
new
ArrayList
<>());
return
new
PageBeanNew
<>(
0
,
0
,
new
ArrayList
<>());
}
}
// 1008584 化工定制(收益排序)
if
(
StrUtil
.
isNotBlank
(
sortType
))
{
return
listPageIncomeDetailBySortType
(
pageParam
,
paramMap
,
agentId
,
sortType
);
}
// 原逻辑(无排序)
PageBeanNew
<
BookSaleVO
>
pageNew
=
bookDao
.
listPageNew
(
pageParam
,
paramMap
,
"listIncomePage4Agent"
);
PageBeanNew
<
BookSaleVO
>
pageNew
=
bookDao
.
listPageNew
(
pageParam
,
paramMap
,
"listIncomePage4Agent"
);
//填充收益
//填充收益
bookSet
.
setAgentSalesInfo
(
pageNew
.
getRecordList
(),
agentId
);
bookSet
.
setAgentSalesInfo
(
pageNew
.
getRecordList
(),
agentId
);
return
pageNew
;
return
pageNew
;
}
}
private
PageBeanNew
<
BookSaleVO
>
listPageIncomeDetailBySortType
(
PageParam
pageParam
,
Map
<
String
,
Object
>
paramMap
,
Long
agentId
,
String
sortType
)
{
Long
count
=
bookDao
.
countIncomePage4Agent
(
paramMap
);
if
(
count
>
BookProps
.
getAgentBookIncomeSortLimitCount
())
{
throw
new
BizException
(
BizException
.
DB_DML_FAIL
.
getCode
(),
"数量超过限制,请添加条件再排序"
);
}
// 查询所有数据
List
<
BookSaleVO
>
list
=
bookDao
.
listIncomePage4Agent
(
paramMap
);
//填充收益
bookSet
.
setAgentSalesInfo4Times
(
list
,
agentId
);
// 内存分页
String
[]
split
=
sortType
.
split
(
"-"
);
String
sortField
=
split
[
0
];
String
ascDesc
=
split
[
1
];
if
(
"adviserIncome"
.
equalsIgnoreCase
(
sortField
))
{
list
=
list
.
stream
().
sorted
(
incomeComparator
(
ascDesc
,
(
BookSaleVO
x
)
->
x
.
getAgentBookIncomeDTO
().
getAdviserIncome
()))
.
skip
(
pageParam
.
getPageNum
()
*
pageParam
.
getNumPerPage
())
.
limit
(
pageParam
.
getNumPerPage
()).
collect
(
Collectors
.
toList
());
}
else
if
(
"agentIncome"
.
equalsIgnoreCase
(
sortField
))
{
list
=
list
.
stream
().
sorted
(
incomeComparator
(
ascDesc
,
(
BookSaleVO
x
)
->
x
.
getAgentBookIncomeDTO
().
getAgentIncome
()))
.
skip
(
pageParam
.
getPageNum
()
*
pageParam
.
getNumPerPage
())
.
limit
(
pageParam
.
getNumPerPage
()).
collect
(
Collectors
.
toList
());
}
else
{
list
=
list
.
stream
().
sorted
(
incomeComparator
(
ascDesc
,
(
BookSaleVO
x
)
->
x
.
getAgentBookIncomeDTO
().
getBookIncome
()))
.
skip
(
pageParam
.
getPageNum
()
*
pageParam
.
getNumPerPage
())
.
limit
(
pageParam
.
getNumPerPage
()).
collect
(
Collectors
.
toList
());
}
// 构建结果
return
new
PageBeanNew
<>(
pageParam
.
getPageNum
(),
pageParam
.
getNumPerPage
(),
count
.
intValue
(),
list
);
}
public
Comparator
<?
super
BookSaleVO
>
incomeComparator
(
String
ascDesc
,
Function
<
BookSaleVO
,
BigDecimal
>
keyExtractor
){
return
"0"
.
equalsIgnoreCase
(
ascDesc
)
?
Comparator
.
comparing
(
keyExtractor
).
reversed
()
:
Comparator
.
comparing
(
keyExtractor
);
}
/**
/**
* 时代大屏用
* 时代大屏用
*/
*/
...
@@ -2350,7 +2399,7 @@ public class BookBizImpl implements BookBiz {
...
@@ -2350,7 +2399,7 @@ public class BookBizImpl implements BookBiz {
Integer
cu
=
100
;
Integer
cu
=
100
;
Integer
p
=
(
count
.
intValue
()
/
cu
)
+
1
;
Integer
p
=
(
count
.
intValue
()
/
cu
)
+
1
;
for
(
int
i
=
0
;
i
<
p
;
i
++)
{
for
(
int
i
=
0
;
i
<
p
;
i
++)
{
PageBeanNew
<
BookSaleVO
>
pageBeanNew
=
listPageIncomeDetail
(
new
PageParam
(
i
,
cu
),
paramMap
,
agentId
);
PageBeanNew
<
BookSaleVO
>
pageBeanNew
=
listPageIncomeDetail
(
new
PageParam
(
i
,
cu
),
paramMap
,
agentId
,
null
);
List
<
BookSaleVO
>
bookSaleVOS
=
pageBeanNew
.
getRecordList
();
List
<
BookSaleVO
>
bookSaleVOS
=
pageBeanNew
.
getRecordList
();
list
.
addAll
(
bookSaleVOS
);
list
.
addAll
(
bookSaleVOS
);
}
}
...
@@ -2408,7 +2457,7 @@ public class BookBizImpl implements BookBiz {
...
@@ -2408,7 +2457,7 @@ public class BookBizImpl implements BookBiz {
Integer
cu
=
100
;
Integer
cu
=
100
;
Integer
p
=
(
count
.
intValue
()
/
cu
)
+
1
;
Integer
p
=
(
count
.
intValue
()
/
cu
)
+
1
;
for
(
int
i
=
0
;
i
<
p
;
i
++)
{
for
(
int
i
=
0
;
i
<
p
;
i
++)
{
PageBeanNew
<
BookSaleVO
>
pageBeanNew
=
listPageIncomeDetail
(
new
PageParam
(
i
,
cu
),
paramMap
,
agentId
);
PageBeanNew
<
BookSaleVO
>
pageBeanNew
=
listPageIncomeDetail
(
new
PageParam
(
i
,
cu
),
paramMap
,
agentId
,
null
);
List
<
BookSaleVO
>
bookSaleVOS
=
pageBeanNew
.
getRecordList
();
List
<
BookSaleVO
>
bookSaleVOS
=
pageBeanNew
.
getRecordList
();
list
.
addAll
(
bookSaleVOS
);
list
.
addAll
(
bookSaleVOS
);
}
}
...
@@ -2436,7 +2485,32 @@ public class BookBizImpl implements BookBiz {
...
@@ -2436,7 +2485,32 @@ public class BookBizImpl implements BookBiz {
Date
date
=
new
Date
();
Date
date
=
new
Date
();
String
[]
rowsName
=
{
"序号"
,
"书刊名称"
,
"书刊号"
,
"是否基金书"
,
"主编辑"
,
"运营平台"
,
"销售总额"
,
"编辑收益"
,
"出版社收益"
};
String
[]
rowsName
=
{
"序号"
,
"书刊名称"
,
"书刊号"
,
"是否基金书"
,
"主编辑"
,
"运营平台"
,
"销售总额"
,
"编辑收益"
,
"出版社收益"
};
String
fileName
=
"书刊收益统计--"
+
DateUtils
.
getStrFormTime
(
"yyyyMMdd"
,
date
);
String
fileName
=
"书刊收益统计--"
+
DateUtils
.
getStrFormTime
(
"yyyyMMdd"
,
date
);
String
fileUrl
=
exportConsr
.
exportExcel
(
fileName
,
rowsName
,
dataList
);
List
<
ExportSheetDto
>
exportSheetDtos
=
CollUtil
.
toList
();
// 书刊收益表
ExportSheetDto
sheetDto1
=
new
ExportSheetDto
();
sheetDto1
.
setSheetName
(
"收益明细"
);
sheetDto1
.
setTitle
(
fileName
);
sheetDto1
.
setRowsName
(
rowsName
);
sheetDto1
.
setDataList
(
dataList
);
exportSheetDtos
.
add
(
sheetDto1
);
// 正版授权费
Map
<
String
,
Object
>
exportDetailGenuineList
=
bookConsr
.
getExportDetailGenuineList
(
systemCode
,
partyId
,
4L
);
if
(
CollUtil
.
isNotEmpty
(
exportDetailGenuineList
))
{
ExportSheetDto
sheetDto2
=
new
ExportSheetDto
();
Object
rowsName2
=
exportDetailGenuineList
.
get
(
"rowsName"
);
sheetDto2
.
setSheetName
(
"正版授权费"
);
sheetDto2
.
setTitle
((
String
)
exportDetailGenuineList
.
get
(
"title"
));
sheetDto2
.
setRowsName
(((
JSONArray
)
rowsName2
).
toArray
(
new
String
[((
JSONArray
)
rowsName2
).
size
()]));
sheetDto2
.
setDataList
(
JSONUtil
.
toList
(
exportDetailGenuineList
.
get
(
"dataList"
).
toString
(),
Object
[].
class
));
exportSheetDtos
.
add
(
sheetDto2
);
}
ExportDto
exportDto
=
new
ExportDto
();
exportDto
.
setExportSheetDtos
(
exportSheetDtos
);
String
fileUrl
=
exportConsr
.
exportExcelEx
(
exportDto
);
String
letterType
=
"book_download"
;
String
letterType
=
"book_download"
;
String
content
=
String
.
format
(
"{\"commitTime\":\"%s\",\"type\":\"%s\"}"
,
DateUtils
.
formatDate
(
date
),
fileName
);
String
content
=
String
.
format
(
"{\"commitTime\":\"%s\",\"type\":\"%s\"}"
,
DateUtils
.
formatDate
(
date
),
fileName
);
messageConsr
.
sendLetter
(
partyId
,
partyId
,
content
,
systemCode
,
letterType
,
fileUrl
,
fileName
);
messageConsr
.
sendLetter
(
partyId
,
partyId
,
content
,
systemCode
,
letterType
,
fileUrl
,
fileName
);
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/dao/impl/BookDaoImpl.java
View file @
6b0168ec
...
@@ -355,7 +355,7 @@ public class BookDaoImpl extends BaseDaoImpl<Book> implements BookDao {
...
@@ -355,7 +355,7 @@ public class BookDaoImpl extends BaseDaoImpl<Book> implements BookDao {
public
List
<
Long
>
getBookIdsByIsbn
(
String
isbn
)
{
public
List
<
Long
>
getBookIdsByIsbn
(
String
isbn
)
{
Map
<
String
,
Object
>
paramMap
=
Maps
.
newHashMap
();
Map
<
String
,
Object
>
paramMap
=
Maps
.
newHashMap
();
paramMap
.
put
(
"isbn"
,
isbn
);
paramMap
.
put
(
"isbn"
,
isbn
);
return
super
.
getSqlSession
().
select
One
(
getStatement
(
"getBookIdsByIsbn"
),
paramMap
);
return
super
.
getSqlSession
().
select
List
(
getStatement
(
"getBookIdsByIsbn"
),
paramMap
);
}
}
@Override
@Override
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/facade/BookFacade.java
View file @
6b0168ec
...
@@ -674,6 +674,7 @@ public interface BookFacade {
...
@@ -674,6 +674,7 @@ public interface BookFacade {
@RequestParam
(
value
=
"thirdTempletId"
,
required
=
false
)
Long
thirdTempletId
,
@RequestParam
(
value
=
"thirdTempletId"
,
required
=
false
)
Long
thirdTempletId
,
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"sortType"
,
required
=
false
)
String
sortType
,
@RequestParam
(
value
=
"minimumSupport"
,
required
=
false
)
Integer
minimumSupport
)
@RequestParam
(
value
=
"minimumSupport"
,
required
=
false
)
Integer
minimumSupport
)
throws
BizException
,
PermissionException
,
JsonParseException
;
throws
BizException
,
PermissionException
,
JsonParseException
;
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/facade/impl/BookFacadeImpl.java
View file @
6b0168ec
...
@@ -1057,6 +1057,7 @@ public class BookFacadeImpl implements BookFacade {
...
@@ -1057,6 +1057,7 @@ public class BookFacadeImpl implements BookFacade {
@RequestParam
(
value
=
"thirdTempletId"
,
required
=
false
)
Long
thirdTempletId
,
@RequestParam
(
value
=
"thirdTempletId"
,
required
=
false
)
Long
thirdTempletId
,
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"sortType"
,
required
=
false
)
String
sortType
,
@RequestParam
(
value
=
"minimumSupport"
,
required
=
false
)
Integer
minimumSupport
)
@RequestParam
(
value
=
"minimumSupport"
,
required
=
false
)
Integer
minimumSupport
)
throws
BizException
,
PermissionException
{
throws
BizException
,
PermissionException
{
Long
agentId
=
(
Long
)
SessionUtil
.
getVlaue
(
token
,
SessionUtil
.
PARTY_ID
);
Long
agentId
=
(
Long
)
SessionUtil
.
getVlaue
(
token
,
SessionUtil
.
PARTY_ID
);
...
@@ -1076,7 +1077,7 @@ public class BookFacadeImpl implements BookFacade {
...
@@ -1076,7 +1077,7 @@ public class BookFacadeImpl implements BookFacade {
paramMap
.
put
(
"minimumSupport"
,
minimumSupport
);
paramMap
.
put
(
"minimumSupport"
,
minimumSupport
);
paramMap
.
put
(
"startTime"
,
StringUtil
.
trimToNull
(
startTime
));
paramMap
.
put
(
"startTime"
,
StringUtil
.
trimToNull
(
startTime
));
paramMap
.
put
(
"endTime"
,
StringUtil
.
trimToNull
(
endTime
));
paramMap
.
put
(
"endTime"
,
StringUtil
.
trimToNull
(
endTime
));
return
new
ResponseDto
<>(
bookBiz
.
listPageIncomeDetail
(
new
PageParam
(
currentPage
,
numPerPage
),
paramMap
,
agentId
));
return
new
ResponseDto
<>(
bookBiz
.
listPageIncomeDetail
(
new
PageParam
(
currentPage
,
numPerPage
),
paramMap
,
agentId
,
sortType
));
}
}
@Override
@Override
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/set/BookSet.java
View file @
6b0168ec
...
@@ -1825,9 +1825,9 @@ public class BookSet {
...
@@ -1825,9 +1825,9 @@ public class BookSet {
},
ThreadPoolUtils
.
OTHER_POOL
);
},
ThreadPoolUtils
.
OTHER_POOL
);
CompletableFuture
.
allOf
(
agentsIncomeFuture
,
adviserNameFuture
,
channelNameFuture
);
CompletableFuture
.
allOf
(
agentsIncomeFuture
,
adviserNameFuture
,
channelNameFuture
);
try
{
try
{
agentsIncome
=
agentsIncomeFuture
.
get
(
2
,
TimeUnit
.
SECONDS
);
agentsIncome
=
agentsIncomeFuture
.
get
(
5
,
TimeUnit
.
SECONDS
);
adviserNameMap
=
adviserNameFuture
.
get
(
2
,
TimeUnit
.
SECONDS
);
adviserNameMap
=
adviserNameFuture
.
get
(
5
,
TimeUnit
.
SECONDS
);
channelNameMap
=
channelNameFuture
.
get
(
2
,
TimeUnit
.
SECONDS
);
channelNameMap
=
channelNameFuture
.
get
(
5
,
TimeUnit
.
SECONDS
);
}
catch
(
InterruptedException
|
ExecutionException
|
TimeoutException
e
)
{
}
catch
(
InterruptedException
|
ExecutionException
|
TimeoutException
e
)
{
LOGGER
.
error
(
"[getAgentsIncome] 并行查询收益任务失败! err:{}"
,
e
.
getMessage
(),
e
);
LOGGER
.
error
(
"[getAgentsIncome] 并行查询收益任务失败! err:{}"
,
e
.
getMessage
(),
e
);
}
}
...
...
pcloud-service-book/src/main/java/com/pcloud/book/consumer/common/ExportConsr.java
View file @
6b0168ec
...
@@ -53,4 +53,21 @@ public class ExportConsr {
...
@@ -53,4 +53,21 @@ public class ExportConsr {
return
fileUrl
;
return
fileUrl
;
}
}
/**
* Excel 多sheet导出
*/
public
String
exportExcelEx
(
ExportDto
exportDto
)
{
LOGGER
.
info
(
"Excel 多sheet导出"
);
String
fileUrl
=
""
;
try
{
ResponseEntity
<
ResponseDto
<
String
>>
response
=
exportService
.
exportExcelEx
(
exportDto
);
fileUrl
=
ResponseHandleUtil
.
parseResponse
(
response
,
String
.
class
);
LOGGER
.
info
(
"Excel导出,return:{}"
,
fileUrl
);
return
fileUrl
;
}
catch
(
Exception
e
)
{
LOGGER
.
error
(
"Excel导出失败[exportService.exportExcelEx]>>>>> {}"
,
e
.
getMessage
(),
e
);
}
return
fileUrl
;
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/consumer/settlement/BookConsr.java
View file @
6b0168ec
...
@@ -153,4 +153,15 @@ public class BookConsr {
...
@@ -153,4 +153,15 @@ public class BookConsr {
}
}
return
qrcodeIncome
;
return
qrcodeIncome
;
}
}
@ParamLog
(
value
=
"获取正版授权导出数据"
,
isBefore
=
false
,
isAfterReturn
=
false
)
public
Map
<
String
,
Object
>
getExportDetailGenuineList
(
String
systemCode
,
Long
partyId
,
Long
roleId
)
{
Map
<
String
,
Object
>
sheetMap
=
new
HashMap
<>();
try
{
sheetMap
=
ResponseHandleUtil
.
parseMap
(
bookService
.
getExportDetailGenuineList
(
systemCode
,
partyId
,
roleId
),
String
.
class
,
Object
.
class
);
}
catch
(
Exception
e
)
{
LOGGER
.
error
(
"获取正版授权导出数据.[getExportDetailGenuineList]:{}"
,
e
.
getMessage
(),
e
);
}
return
sheetMap
;
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/util/properties/BookProps.java
View file @
6b0168ec
...
@@ -54,6 +54,17 @@ public class BookProps {
...
@@ -54,6 +54,17 @@ public class BookProps {
//可以忽略的公众号id
//可以忽略的公众号id
private
static
List
<
Long
>
ignorOfficialAccountsId
;
private
static
List
<
Long
>
ignorOfficialAccountsId
;
private
static
Integer
agentBookIncomeSortLimitCount
;
public
static
Integer
getAgentBookIncomeSortLimitCount
()
{
return
agentBookIncomeSortLimitCount
;
}
@NacosValue
(
value
=
"${agent.book.income.sort.limit.count:1500}"
,
autoRefreshed
=
true
)
public
void
setAgentBookIncomeSortLimitCount
(
Integer
agentBookIncomeSortLimitCount
)
{
BookProps
.
agentBookIncomeSortLimitCount
=
agentBookIncomeSortLimitCount
;
}
public
static
List
<
Long
>
getIgnorOfficialAccountsId
()
{
public
static
List
<
Long
>
getIgnorOfficialAccountsId
()
{
return
ignorOfficialAccountsId
;
return
ignorOfficialAccountsId
;
}
}
...
...
pcloud-service-book/src/main/resources/mapper/book/Book.Mapper.xml
View file @
6b0168ec
...
@@ -2852,7 +2852,7 @@
...
@@ -2852,7 +2852,7 @@
<select
id=
"getBookIdsByIsbn"
parameterType=
"map"
resultType=
"long"
>
<select
id=
"getBookIdsByIsbn"
parameterType=
"map"
resultType=
"long"
>
select DISTINCT book_id
select DISTINCT book_id
from BOOK
from BOOK
where isbn like concat(
'%',
#{isbn},'%')
where isbn like concat(#{isbn},'%')
</select>
</select>
<select
id=
"getAddBookQualifyList"
resultType=
"com.pcloud.book.book.vo.BookQualifyVO"
parameterType=
"map"
>
<select
id=
"getAddBookQualifyList"
resultType=
"com.pcloud.book.book.vo.BookQualifyVO"
parameterType=
"map"
>
...
...
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