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
96034f72
Commit
96034f72
authored
Jul 19, 2019
by
hezhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
123
parent
476925db
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
5 deletions
+12
-5
RabbitConstant.java
...wxiaoqi/security/common/config/rabbit/RabbitConstant.java
+2
-0
RegisterQueueDTO.java
...m/github/wxiaoqi/security/admin/dto/RegisterQueueDTO.java
+1
-1
AppPermissionService.java
...aoqi/security/admin/rpc/service/AppPermissionService.java
+6
-2
PopularizeMQHandler.java
...m/xxfc/platform/activity/handler/PopularizeMQHandler.java
+3
-2
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/config/rabbit/RabbitConstant.java
View file @
96034f72
...
...
@@ -22,6 +22,8 @@ public class RabbitConstant {
public
static
final
String
KEY_ORDER_PAY
=
"order.pay"
;
public
static
final
String
KEY_ORDER_FINLISH
=
"order.finlish"
;
public
static
final
String
KEY_ORDER_CANCEL
=
"order.cancel"
;
public
static
final
String
INTEGRAL_ROUTING_KEY
=
"integral_routing_key"
;
static
{
exchangeTopicSet
=
new
HashSet
<
String
>()
{{
add
(
ADMIN_TOPIC
);
...
...
ace-modules/ace-admin-api/src/main/java/com/github/wxiaoqi/security/admin/dto/RegisterQueueDTO.java
View file @
96034f72
...
...
@@ -12,7 +12,7 @@ public class RegisterQueueDTO {
/**
* 执行方法的入参
*/
RegisterParamDTO
I
nParamDTO
;
RegisterParamDTO
i
nParamDTO
;
/**
* app用户id
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/rpc/service/AppPermissionService.java
View file @
96034f72
...
...
@@ -216,6 +216,7 @@ public class AppPermissionService {
public
JSONObject
register
(
String
username
,
String
password
,
String
headimgurl
,
String
nickname
,
String
mobilecode
,
String
openId
,
String
unionid
,
Integer
type
,
String
code
)
{
String
activityCode
=
null
;
String
inviterCode
=
null
;
// 判断参数和验证码
if
(
StringUtils
.
isBlank
(
username
)
||
StringUtils
.
isBlank
(
password
)
||
StringUtils
.
isBlank
(
mobilecode
))
{
...
...
@@ -271,11 +272,14 @@ public class AppPermissionService {
setCreateIPInfo
(
rsUserDetail
);
//邀请人id关系绑定
Integer
parentId
=
0
;
String
code1
=
null
;
if
(
StringUtils
.
isNotBlank
(
code
)){
//判断处理活动关键字
String
[]
codes
=
code
.
split
(
"_"
);
if
(
codes
.
length
>
1
)
{
parentId
=
appUserDetailBiz
.
getUserByCode
(
codes
[
0
]);
activityCode
=
codes
[
1
];
inviterCode
=
codes
[
0
];
parentId
=
appUserDetailBiz
.
getUserByCode
(
inviterCode
);
}
}
if
(
parentId
!=
null
&&
parentId
>
0
){
...
...
@@ -316,7 +320,7 @@ public class AppPermissionService {
data
.
put
(
"imUserId"
,
imUserId
);
}
if
(
data
!=
null
)
{
sendQueue
(
username
,
password
,
headimgurl
,
nickname
,
mobilecode
,
openId
,
unionid
,
type
,
c
ode
,
activityCode
,
userid
,
RegisterQueueDTO
.
SIGN_NEW
);
sendQueue
(
username
,
password
,
headimgurl
,
nickname
,
mobilecode
,
openId
,
unionid
,
type
,
inviterC
ode
,
activityCode
,
userid
,
RegisterQueueDTO
.
SIGN_NEW
);
return
JsonResultUtil
.
createSuccessResultWithObj
(
data
);
}
else
{
return
JsonResultUtil
.
createDefaultFail
();
...
...
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/handler/PopularizeMQHandler.java
View file @
96034f72
package
com
.
xxfc
.
platform
.
activity
.
handler
;
import
cn.hutool.json.JSONUtil
;
import
com.alibaba.fastjson.JSONObject
;
import
com.github.wxiaoqi.security.admin.dto.RegisterQueueDTO
;
import
com.rabbitmq.client.Channel
;
...
...
@@ -47,7 +48,7 @@ public class PopularizeMQHandler {
log
.
info
(
"接收到的消息:msg = {}, 消息ID是:messageId = {} "
,
msg
,
messageId
);
if
(
StringUtils
.
isNotBlank
(
msg
))
{
RegisterQueueDTO
registerQueueDTO
=
JSON
Object
.
parseObject
(
msg
,
RegisterQueueDTO
.
class
);
RegisterQueueDTO
registerQueueDTO
=
JSON
Util
.
toBean
(
msg
,
RegisterQueueDTO
.
class
);
activityPopularizeBiz
.
handleRegister
(
registerQueueDTO
);
}
...
...
@@ -80,7 +81,7 @@ public class PopularizeMQHandler {
log
.
info
(
"接收到的消息:msg = {}, 消息ID是:messageId = {} "
,
msg
,
messageId
);
if
(
StringUtils
.
isNotBlank
(
msg
))
{
RegisterQueueDTO
registerQueueDTO
=
JSON
Object
.
parseObject
(
msg
,
RegisterQueueDTO
.
class
);
RegisterQueueDTO
registerQueueDTO
=
JSON
Util
.
toBean
(
msg
,
RegisterQueueDTO
.
class
);
if
(
registerQueueDTO
!=
null
&&(
registerQueueDTO
.
getSign
()==
RegisterQueueDTO
.
SIGN_NEW
||
registerQueueDTO
.
getSign
()==
RegisterQueueDTO
.
SIGN_ACTIVATE
)){
activityUserJoinBiz
.
joinActivity
(
registerQueueDTO
.
getAppUserId
());
}
...
...
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