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
7ac40b38
Commit
7ac40b38
authored
Oct 11, 2019
by
hezhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
123
parent
b0691a90
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
10 deletions
+14
-10
UserBiz.java
...r/src/main/java/com/xxfc/platform/summit/biz/UserBiz.java
+9
-7
WeixinController.java
...com/xxfc/platform/summit/controller/WeixinController.java
+5
-3
No files found.
xx-summit/xx-summit-server/src/main/java/com/xxfc/platform/summit/biz/UserBiz.java
View file @
7ac40b38
...
@@ -92,7 +92,7 @@ public class UserBiz extends BaseBiz<UserMapper, User> {
...
@@ -92,7 +92,7 @@ public class UserBiz extends BaseBiz<UserMapper, User> {
return
userId
;
return
userId
;
}
}
public
void
authUser
(
String
code
,
String
key
,
HttpServletRequest
request
){
public
void
authUser
(
String
code
,
String
key
,
Integer
activityId
,
HttpServletRequest
request
){
if
(
StringUtils
.
isBlank
(
code
)){
if
(
StringUtils
.
isBlank
(
code
)){
log
.
info
(
"----code为空---"
);
log
.
info
(
"----code为空---"
);
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"code为空"
));
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"code为空"
));
...
@@ -125,12 +125,14 @@ public class UserBiz extends BaseBiz<UserMapper, User> {
...
@@ -125,12 +125,14 @@ public class UserBiz extends BaseBiz<UserMapper, User> {
throw new BaseException(ResultCode.FAILED_CODE, Sets.newSet("调用微信用户基本信息接口失败"));
throw new BaseException(ResultCode.FAILED_CODE, Sets.newSet("调用微信用户基本信息接口失败"));
}
}
log.info("微信用户基本信息---user===" +userinfo_json.toJSONString());*/
log.info("微信用户基本信息---user===" +userinfo_json.toJSONString());*/
if
(
activityId
==
null
||
activityId
==
0
){
ActivityBm
activityBm
=
activityBmBiz
.
userInfo
(
key
);
ActivityBm
activityBm
=
activityBmBiz
.
userInfo
(
key
);
if
(
activityBm
==
null
){
if
(
activityBm
==
null
){
log
.
info
(
"redis的报名信息为空"
);
log
.
info
(
"redis的报名信息为空"
);
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"redis的报名信息为空"
));
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"redis的报名信息为空"
));
}
}
Integer
activityId
=
activityBm
.
getActivityId
();
activityId
=
activityBm
.
getActivityId
();
}
if
(
activityId
==
null
||
activityId
==
0
){
if
(
activityId
==
null
||
activityId
==
0
){
log
.
info
(
"redis的报名信息activityId---为空"
);
log
.
info
(
"redis的报名信息activityId---为空"
);
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"redis的报名信息activityId---为空"
));
throw
new
BaseException
(
ResultCode
.
FAILED_CODE
,
Sets
.
newSet
(
"redis的报名信息activityId---为空"
));
...
...
xx-summit/xx-summit-server/src/main/java/com/xxfc/platform/summit/controller/WeixinController.java
View file @
7ac40b38
...
@@ -83,11 +83,13 @@ public class WeixinController {
...
@@ -83,11 +83,13 @@ public class WeixinController {
key
=
RedisKey
.
CONSTANT_CODE_PREFIX
+
params
[
1
];
key
=
RedisKey
.
CONSTANT_CODE_PREFIX
+
params
[
1
];
}
}
params
=
callback
.
split
(
"_"
);
params
=
callback
.
split
(
"_"
);
Integer
activityId
=
0
;
if
(
params
.
length
>
1
){
if
(
params
.
length
>
1
){
key
=
RedisKey
.
CONSTANT_CODE_PREFIX
+
params
[
1
];
callback
=
params
[
0
];
activityId
=
Integer
.
parseInt
(
params
[
1
]);
}
}
log
.
info
(
"-----微信回调userInfo---key=="
+
key
+
"----callback==="
+
callback
);
log
.
info
(
"-----微信回调userInfo---key=="
+
key
+
"----
activityId==="
+
activityId
+
"----
callback==="
+
callback
);
userBiz
.
authUser
(
code
,
key
,
request
);
userBiz
.
authUser
(
code
,
key
,
activityId
,
request
);
//callback =new String(Base64.decode(callback), "utf-8");
//callback =new String(Base64.decode(callback), "utf-8");
callback
+=
"&key="
+
key
;
callback
+=
"&key="
+
key
;
log
.
info
(
"callback==="
+
callback
);
log
.
info
(
"callback==="
+
callback
);
...
...
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