Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cash-loan-flow-boss
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
QG
cash-loan-flow-boss
Commits
227d5f64
Commit
227d5f64
authored
Sep 23, 2019
by
suntao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
渠道信息编辑
parent
3fef99b3
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
38 additions
and
9 deletions
+38
-9
ChannelConfController.java
...lowboss/api/channel/controller/ChannelConfController.java
+11
-1
CLFCenter.java
...uantgroup/cashloanflowboss/spi/clf/service/CLFCenter.java
+17
-8
CLFCenterService.java
...up/cashloanflowboss/spi/clf/service/CLFCenterService.java
+2
-0
CLFCenterServiceImpl.java
...ashloanflowboss/spi/clf/service/CLFCenterServiceImpl.java
+8
-0
No files found.
src/main/java/cn/quantgroup/cashloanflowboss/api/channel/controller/ChannelConfController.java
View file @
227d5f64
...
...
@@ -6,6 +6,7 @@ import cn.quantgroup.cashloanflowboss.component.security.annotiation.Security;
import
cn.quantgroup.cashloanflowboss.core.annotation.ChannelIdInit
;
import
cn.quantgroup.cashloanflowboss.core.annotation.CheckChannelRole
;
import
cn.quantgroup.cashloanflowboss.core.base.Result
;
import
cn.quantgroup.cashloanflowboss.spi.clf.service.CLFCenterService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
...
...
@@ -23,6 +24,8 @@ public class ChannelConfController {
@Autowired
private
ChannelConfService
channelConfService
;
@Autowired
private
CLFCenterService
clfCenterService
;
/**
...
...
@@ -67,7 +70,14 @@ public class ChannelConfController {
@CheckChannelRole
(
isObjParam
=
true
,
paramClazz
=
ChannelConfVo
.
class
)
@PostMapping
(
"/cfg/info"
)
public
Result
editChannelConfInfo
(
@RequestBody
@Valid
ChannelConfVo
channelConfVo
)
{
return
Result
.
buildSuccess
(
channelConfService
.
editChannelConfInfo
(
channelConfVo
));
Boolean
aBoolean
=
channelConfService
.
editChannelConfInfo
(
channelConfVo
);
if
(
aBoolean
)
{
// 属性ka缓存
clfCenterService
.
reloadKAConfiguration
();
}
return
Result
.
buildSuccess
(
aBoolean
?
"编辑修改成功"
:
"编辑修改失败"
);
}
...
...
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/service/CLFCenter.java
View file @
227d5f64
...
...
@@ -2,6 +2,7 @@ package cn.quantgroup.cashloanflowboss.spi.clf.service;
import
org.springframework.cloud.netflix.feign.FeignClient
;
import
org.springframework.stereotype.Component
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
...
...
@@ -9,17 +10,25 @@ import org.springframework.web.bind.annotation.RequestParam;
@FeignClient
(
name
=
"CLFServiceCenter"
,
url
=
"${qapi.https}"
,
fallback
=
CLFCenter
.
Fallback
.
class
)
public
interface
CLFCenter
{
@PostMapping
(
value
=
"/test//loanMq/batch"
,
consumes
=
"application/x-www-form-urlencoded"
)
public
void
loanMq
(
@RequestParam
(
"json"
)
String
loanMq
);
@PostMapping
(
value
=
"/test//loanMq/batch"
,
consumes
=
"application/x-www-form-urlencoded"
)
void
loanMq
(
@RequestParam
(
"json"
)
String
loanMq
);
@Component
class
Fallback
implements
CLFCenter
{
@GetMapping
(
value
=
"/configuration/lPm6usTlPYLqtDPQHIldvszWakDHlDh4"
,
consumes
=
"application/x-www-form-urlencoded"
)
void
reloadKASetting
(
@RequestParam
(
"token"
)
String
token
);
@Override
public
void
loanMq
(
String
loanMq
)
{
return
;
@Component
class
Fallback
implements
CLFCenter
{
@Override
public
void
loanMq
(
String
loanMq
)
{
return
;
}
@Override
public
void
reloadKASetting
(
String
token
)
{
}
}
}
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/service/CLFCenterService.java
View file @
227d5f64
...
...
@@ -34,4 +34,6 @@ public interface CLFCenterService {
void
saveOrderCall
(
List
<
ClfOrderCallBack
>
clfOrderCallBackList
);
ClfOrderCallBack
findOrderCallBackByByCallbackStatusAndChannelId
(
String
name
,
Long
channelId
);
void
reloadKAConfiguration
();
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/service/CLFCenterServiceImpl.java
View file @
227d5f64
...
...
@@ -25,6 +25,9 @@ import java.util.Objects;
public
class
CLFCenterServiceImpl
implements
CLFCenterService
{
@Autowired
private
CLFCenter
clfCenter
;
@Autowired
private
CallbackFailRecordRepository
callbackFailRecordRepository
;
@Autowired
...
...
@@ -132,4 +135,9 @@ public class CLFCenterServiceImpl implements CLFCenterService{
public
ClfOrderCallBack
findOrderCallBackByByCallbackStatusAndChannelId
(
String
kaNoticeName
,
Long
channelId
)
{
return
clfOrderCallbackRepository
.
findByCallbackStatusAndRegisteredFrom
(
kaNoticeName
,
channelId
);
}
@Override
public
void
reloadKAConfiguration
()
{
clfCenter
.
reloadKASetting
(
""
);
}
}
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