Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
asset-distribution
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
data-spider
asset-distribution
Commits
b437b517
Commit
b437b517
authored
Apr 07, 2020
by
郑建
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
6.6-2
parent
e8f68eb9
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
33 additions
and
13 deletions
+33
-13
FundModuleController.java
...p/asset/distribution/controller/FundModuleController.java
+9
-7
IFundModuleChannelFundConfigNewService.java
...rvice/funding/IFundModuleChannelFundConfigNewService.java
+2
-0
IFundModuleService.java
...sset/distribution/service/funding/IFundModuleService.java
+2
-2
FundModuleChannelFundConfigNewServiceImpl.java
...nding/impl/FundModuleChannelFundConfigNewServiceImpl.java
+11
-0
FundModuleServiceImpl.java
...tribution/service/funding/impl/FundModuleServiceImpl.java
+9
-4
No files found.
src/main/java/com/quantgroup/asset/distribution/controller/FundModuleController.java
View file @
b437b517
...
@@ -22,6 +22,8 @@ import com.quantgroup.asset.distribution.util.fund.module.ChannelFundConfigUtil;
...
@@ -22,6 +22,8 @@ import com.quantgroup.asset.distribution.util.fund.module.ChannelFundConfigUtil;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
import
javax.persistence.criteria.CriteriaBuilder
;
/**
/**
* 资方模块Controller
* 资方模块Controller
* @author liwenbin
* @author liwenbin
...
@@ -59,11 +61,11 @@ public class FundModuleController {
...
@@ -59,11 +61,11 @@ public class FundModuleController {
@RequestMapping
(
"/get_channel_fund_configs"
)
@RequestMapping
(
"/get_channel_fund_configs"
)
public
GlobalResponse
getChannelFundConfigs
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
)
{
public
GlobalResponse
getChannelFundConfigs
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
)
{
return
getChannelFundsConfigCommon
(
bizChannel
,
fundId
,
pageNum
,
pageSize
,
1
);
return
getChannelFundsConfigCommon
(
bizChannel
,
fundId
,
pageNum
,
pageSize
,
1
,
null
);
}
}
@RequestMapping
(
"/get_audit_infos"
)
@RequestMapping
(
"/get_audit_infos"
)
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
)
{
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
)
{
log
.
info
(
"资方模块接口, 获取审批列表开始, targetName : {}, auditStatus : {}, auditType : {}, auditTarget : {}, applyStartTime : {}, applyEndTime : {}, user : {}, pageNum : {}, pageSize : {}"
,
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
);
log
.
info
(
"资方模块接口, 获取审批列表开始, targetName : {}, auditStatus : {}, auditType : {}, auditTarget : {}, applyStartTime : {}, applyEndTime : {}, user : {}, pageNum : {}, pageSize : {}"
,
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
);
if
(
pageNum
==
null
||
pageSize
==
null
)
{
if
(
pageNum
==
null
||
pageSize
==
null
)
{
return
GlobalResponse
.
create
(
FundModuleResponse
.
PAGEING_CONDITIONS_IS_EMPTY
);
return
GlobalResponse
.
create
(
FundModuleResponse
.
PAGEING_CONDITIONS_IS_EMPTY
);
...
@@ -72,7 +74,7 @@ public class FundModuleController {
...
@@ -72,7 +74,7 @@ public class FundModuleController {
return
GlobalResponse
.
create
(
FundModuleResponse
.
USER_IS_EMPTY
);
return
GlobalResponse
.
create
(
FundModuleResponse
.
USER_IS_EMPTY
);
}
}
Stopwatch
stopwatch
=
Stopwatch
.
createStarted
();
Stopwatch
stopwatch
=
Stopwatch
.
createStarted
();
GlobalResponse
response
=
fundModuleService
.
getAuditInfos
(
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
,
sortMode
);
GlobalResponse
response
=
fundModuleService
.
getAuditInfos
(
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
);
log
.
info
(
"资方模块接口, 获取审批列表结束, targetName : {}, auditStatus : {}, auditType : {}, auditTarget : {}, applyStartTime : {}, applyEndTime : {}, user : {}, pageNum : {}, pageSize : {}, 耗时 : {}, response : {}"
,
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
,
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
JSON
.
toJSONString
(
response
));
log
.
info
(
"资方模块接口, 获取审批列表结束, targetName : {}, auditStatus : {}, auditType : {}, auditTarget : {}, applyStartTime : {}, applyEndTime : {}, user : {}, pageNum : {}, pageSize : {}, 耗时 : {}, response : {}"
,
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
,
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
JSON
.
toJSONString
(
response
));
return
response
;
return
response
;
}
}
...
@@ -104,8 +106,8 @@ public class FundModuleController {
...
@@ -104,8 +106,8 @@ public class FundModuleController {
}
}
@RequestMapping
(
"/get_channel_fund_configs_new"
)
@RequestMapping
(
"/get_channel_fund_configs_new"
)
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
)
{
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
)
{
return
getChannelFundsConfigCommon
(
bizChannel
,
fundId
,
pageNum
,
pageSize
,
2
);
return
getChannelFundsConfigCommon
(
bizChannel
,
fundId
,
pageNum
,
pageSize
,
2
,
sortMode
);
}
}
@RequestMapping
(
"/find_channel_fund_config_new"
)
@RequestMapping
(
"/find_channel_fund_config_new"
)
...
@@ -169,7 +171,7 @@ public class FundModuleController {
...
@@ -169,7 +171,7 @@ public class FundModuleController {
return
response
;
return
response
;
}
}
private
GlobalResponse
getChannelFundsConfigCommon
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
,
int
oldOrNew
)
{
private
GlobalResponse
getChannelFundsConfigCommon
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
,
int
oldOrNew
,
Integer
sortMode
)
{
log
.
info
(
"资方模块接口, 查询渠道资方配置信息开始, bizChannel : {}, fundId : {}, pageNum : {}, pageSize : {}"
,
bizChannel
,
fundId
,
pageNum
,
pageSize
);
log
.
info
(
"资方模块接口, 查询渠道资方配置信息开始, bizChannel : {}, fundId : {}, pageNum : {}, pageSize : {}"
,
bizChannel
,
fundId
,
pageNum
,
pageSize
);
if
(
pageNum
==
null
||
pageSize
==
null
)
{
if
(
pageNum
==
null
||
pageSize
==
null
)
{
return
GlobalResponse
.
create
(
FundModuleResponse
.
PAGEING_CONDITIONS_IS_EMPTY
);
return
GlobalResponse
.
create
(
FundModuleResponse
.
PAGEING_CONDITIONS_IS_EMPTY
);
...
@@ -180,7 +182,7 @@ public class FundModuleController {
...
@@ -180,7 +182,7 @@ public class FundModuleController {
// 老接口
// 老接口
response
=
fundModuleService
.
getChannelFundConfigs
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
response
=
fundModuleService
.
getChannelFundConfigs
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
}
else
{
}
else
{
response
=
fundModuleService
.
getChannelFundConfigsNew
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
response
=
fundModuleService
.
getChannelFundConfigsNew
(
bizChannel
,
fundId
,
pageNum
,
pageSize
,
sortMode
);
}
}
log
.
info
(
"资方模块接口, 查询渠道资方配置信息结束, bizChannel : {}, fundId : {}, pageNum : {}, pageSize : {}, 耗时 : {}, response : {}"
,
bizChannel
,
fundId
,
pageNum
,
pageSize
,
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
JSON
.
toJSONString
(
response
));
log
.
info
(
"资方模块接口, 查询渠道资方配置信息结束, bizChannel : {}, fundId : {}, pageNum : {}, pageSize : {}, 耗时 : {}, response : {}"
,
bizChannel
,
fundId
,
pageNum
,
pageSize
,
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
JSON
.
toJSONString
(
response
));
...
...
src/main/java/com/quantgroup/asset/distribution/service/funding/IFundModuleChannelFundConfigNewService.java
View file @
b437b517
...
@@ -28,5 +28,7 @@ public interface IFundModuleChannelFundConfigNewService {
...
@@ -28,5 +28,7 @@ public interface IFundModuleChannelFundConfigNewService {
public
void
clearChannelFundConfigCache
(
String
bizChannel
);
public
void
clearChannelFundConfigCache
(
String
bizChannel
);
Map
<
String
,
Object
>
getChannelFundConfigsByChannelOrFundIdOrdered
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
);
public
List
<
String
>
getAllConfigChanels
();
public
List
<
String
>
getAllConfigChanels
();
}
}
src/main/java/com/quantgroup/asset/distribution/service/funding/IFundModuleService.java
View file @
b437b517
...
@@ -65,7 +65,7 @@ public interface IFundModuleService {
...
@@ -65,7 +65,7 @@ public interface IFundModuleService {
* @param pageSize
* @param pageSize
* @return
* @return
*/
*/
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
);
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
);
/**
/**
* 获取审批列表
* 获取审批列表
...
@@ -80,7 +80,7 @@ public interface IFundModuleService {
...
@@ -80,7 +80,7 @@ public interface IFundModuleService {
* @param pageSize
* @param pageSize
* @return
* @return
*/
*/
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
);
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
);
/**
/**
* 根据Id获取资方配置
* 根据Id获取资方配置
...
...
src/main/java/com/quantgroup/asset/distribution/service/funding/impl/FundModuleChannelFundConfigNewServiceImpl.java
View file @
b437b517
...
@@ -8,6 +8,7 @@ import com.quantgroup.asset.distribution.exception.QGExceptionType;
...
@@ -8,6 +8,7 @@ import com.quantgroup.asset.distribution.exception.QGExceptionType;
import
com.quantgroup.asset.distribution.model.response.GlobalResponse
;
import
com.quantgroup.asset.distribution.model.response.GlobalResponse
;
import
com.quantgroup.asset.distribution.service.approval.IApprovalLogService
;
import
com.quantgroup.asset.distribution.service.approval.IApprovalLogService
;
import
com.quantgroup.asset.distribution.service.funding.IFundModuleChannelFundConfigNewService
;
import
com.quantgroup.asset.distribution.service.funding.IFundModuleChannelFundConfigNewService
;
import
com.quantgroup.asset.distribution.service.jpa.entity.ApprovalLog
;
import
com.quantgroup.asset.distribution.service.jpa.entity.FundModuleChannelFundConfig
;
import
com.quantgroup.asset.distribution.service.jpa.entity.FundModuleChannelFundConfig
;
import
com.quantgroup.asset.distribution.service.jpa.entity.FundModuleChannelFundConfigNew
;
import
com.quantgroup.asset.distribution.service.jpa.entity.FundModuleChannelFundConfigNew
;
import
com.quantgroup.asset.distribution.service.jpa.repository.IFundModuleChannelFundConfigNewRepository
;
import
com.quantgroup.asset.distribution.service.jpa.repository.IFundModuleChannelFundConfigNewRepository
;
...
@@ -30,6 +31,7 @@ import javax.persistence.criteria.CriteriaQuery;
...
@@ -30,6 +31,7 @@ import javax.persistence.criteria.CriteriaQuery;
import
javax.persistence.criteria.Predicate
;
import
javax.persistence.criteria.Predicate
;
import
javax.persistence.criteria.Root
;
import
javax.persistence.criteria.Root
;
import
java.util.*
;
import
java.util.*
;
import
java.util.stream.Collectors
;
/**
/**
* @author : Hyuk
* @author : Hyuk
...
@@ -155,6 +157,15 @@ public class FundModuleChannelFundConfigNewServiceImpl implements IFundModuleCha
...
@@ -155,6 +157,15 @@ public class FundModuleChannelFundConfigNewServiceImpl implements IFundModuleCha
log
.
info
(
"渠道资方配置缓存清除, bizChannel : {}"
,
bizChannel
);
log
.
info
(
"渠道资方配置缓存清除, bizChannel : {}"
,
bizChannel
);
}
}
@Override
public
Map
<
String
,
Object
>
getChannelFundConfigsByChannelOrFundIdOrdered
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
)
{
Map
<
String
,
Object
>
map
=
approvalLogService
.
getApprovalLogs
(
bizChannel
,
null
,
null
,
1
,
null
,
null
,
null
,
pageNum
,
pageSize
,
1
);
List
<
ApprovalLog
>
logs
=
(
List
<
ApprovalLog
>)
map
.
get
(
"list"
);
List
<
Long
>
configIds
=
logs
.
stream
().
collect
(
ArrayList:
:
new
,(
l
,
i
)->
l
.
add
(
i
.
getAuditConfigId
()),
ArrayList:
:
addAll
);
return
null
;
}
@Override
@Override
public
List
<
String
>
getAllConfigChanels
()
{
public
List
<
String
>
getAllConfigChanels
()
{
return
fundModuleChannelFundConfigNewRepository
.
getAllBizChannel
();
return
fundModuleChannelFundConfigNewRepository
.
getAllBizChannel
();
...
...
src/main/java/com/quantgroup/asset/distribution/service/funding/impl/FundModuleServiceImpl.java
View file @
b437b517
...
@@ -139,8 +139,13 @@ public class FundModuleServiceImpl implements IFundModuleService{
...
@@ -139,8 +139,13 @@ public class FundModuleServiceImpl implements IFundModuleService{
@HandleException
@HandleException
@Override
@Override
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
)
{
public
GlobalResponse
getChannelFundConfigsNew
(
String
bizChannel
,
Long
fundId
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
)
{
Map
<
String
,
Object
>
result
=
fundModuleChannelFundConfigNewService
.
getChannelFundConfigsByChannelOrFundId
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
Map
<
String
,
Object
>
result
;
if
(
sortMode
==
2
){
result
=
fundModuleChannelFundConfigNewService
.
getChannelFundConfigsByChannelOrFundIdOrdered
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
}
else
{
result
=
fundModuleChannelFundConfigNewService
.
getChannelFundConfigsByChannelOrFundId
(
bizChannel
,
fundId
,
pageNum
,
pageSize
);
}
if
(
result
==
null
||
result
.
size
()
==
0
)
{
if
(
result
==
null
||
result
.
size
()
==
0
)
{
return
GlobalResponse
.
create
(
FundModuleResponse
.
HAS_NO_DATA
);
return
GlobalResponse
.
create
(
FundModuleResponse
.
HAS_NO_DATA
);
}
}
...
@@ -150,8 +155,8 @@ public class FundModuleServiceImpl implements IFundModuleService{
...
@@ -150,8 +155,8 @@ public class FundModuleServiceImpl implements IFundModuleService{
@HandleException
@HandleException
@Override
@Override
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
public
GlobalResponse
getAuditInfos
(
String
targetName
,
Integer
auditStatus
,
Integer
auditType
,
Integer
auditTarget
,
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
,
Integer
sortMode
)
{
String
applyStartTime
,
String
applyEndTime
,
String
user
,
Integer
pageNum
,
Integer
pageSize
)
{
Map
<
String
,
Object
>
result
=
approvalLogService
.
getApprovalLogs
(
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
,
sortMode
);
Map
<
String
,
Object
>
result
=
approvalLogService
.
getApprovalLogs
(
targetName
,
auditStatus
,
auditType
,
auditTarget
,
applyStartTime
,
applyEndTime
,
user
,
pageNum
,
pageSize
,
null
);
if
(
result
.
size
()
==
0
)
{
if
(
result
.
size
()
==
0
)
{
return
GlobalResponse
.
create
(
FundModuleResponse
.
HAS_NO_DATA
);
return
GlobalResponse
.
create
(
FundModuleResponse
.
HAS_NO_DATA
);
}
}
...
...
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