Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gogirl-miniapp-backend
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
huluobin
gogirl-miniapp-backend
Commits
47206bec
Commit
47206bec
authored
Mar 06, 2020
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
美甲师登陆流程修改 线程变量保存登陆Seesion
parent
370d9127
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
14 deletions
+5
-14
PhoneLoginController.java
.../java/com/gogirl/interfaces/xcx/PhoneLoginController.java
+5
-14
No files found.
src/main/java/com/gogirl/interfaces/xcx/PhoneLoginController.java
View file @
47206bec
...
@@ -102,26 +102,17 @@ public class PhoneLoginController {
...
@@ -102,26 +102,17 @@ public class PhoneLoginController {
@ResponseBody
@ResponseBody
@ApiOperation
(
value
=
"获取验证码,用于绑定手机号码"
)
@ApiOperation
(
value
=
"获取验证码,用于绑定手机号码"
)
@RequestMapping
(
method
=
{
RequestMethod
.
POST
},
value
=
"/technician/getBindCode"
)
@PostMapping
(
"/technician/getBindCode"
)
public
JsonResult
<
String
>
techGetBindCode
(
@RequestParam
String
phone
,
String
token
)
{
public
JsonResult
<
String
>
techGetBindCode
(
@RequestParam
String
phone
)
{
if
(
token
==
null
||
token
.
isEmpty
())
{
return
new
JsonResult
<>(
false
,
"入参token为空"
,
null
);
}
if
(!
CheckUtil
.
isPhone
(
phone
))
{
if
(!
CheckUtil
.
isPhone
(
phone
))
{
log
.
info
(
"用户号码格式不正确"
);
log
.
info
(
"用户号码格式不正确"
);
return
new
JsonResult
<>(
false
,
"用户号码格式不正确"
,
null
);
throw
new
RRException
(
"用户号码格式不正确"
);
}
GogirlToken
gt
=
gogirlTokenService
.
getByToken
(
token
);
if
(
gt
==
null
)
{
return
new
JsonResult
<>(
false
,
"TOKEN_NULL_CODE"
,
"token过期"
);
}
}
String
code
=
getNewCode
();
String
code
=
getNewCode
();
SmsSingleSenderResult
result
=
smsService
.
sendBindSmsCode
(
phone
,
code
);
SmsSingleSenderResult
result
=
smsService
.
sendBindSmsCode
(
phone
,
code
);
if
(
result
!=
null
)
{
if
(
result
!=
null
)
{
//验证码保存到TOKEN
//todo 验证码逻辑
gt
.
setCode
(
code
);
gt
.
setPhone
(
phone
);
gogirlTokenService
.
updateById
(
gt
);
return
new
JsonResult
<>(
true
,
JsonResult
.
APP_DEFINE_SUC
,
null
);
return
new
JsonResult
<>(
true
,
JsonResult
.
APP_DEFINE_SUC
,
null
);
}
else
{
}
else
{
return
new
JsonResult
<>(
false
,
"发送验证码失败,请重试"
,
null
);
return
new
JsonResult
<>(
false
,
"发送验证码失败,请重试"
,
null
);
...
...
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