Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
haoban3.0
haoban-manage3.0
Commits
7f20b3b2
Commit
7f20b3b2
authored
Feb 21, 2022
by
墨竹
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:好办登陆接口修改
parent
ff1635e3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
3 deletions
+7
-3
WxEnterpriseInfoController.java
...ban/manage/web/controller/WxEnterpriseInfoController.java
+6
-2
HaoBanErrCode.java
...java/com/gic/haoban/manage/web/errCode/HaoBanErrCode.java
+1
-1
No files found.
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/controller/WxEnterpriseInfoController.java
View file @
7f20b3b2
...
@@ -187,6 +187,10 @@ public class WxEnterpriseInfoController extends WebBaseController {
...
@@ -187,6 +187,10 @@ public class WxEnterpriseInfoController extends WebBaseController {
if
(
staffDTO
==
null
)
{
if
(
staffDTO
==
null
)
{
return
RestResponse
.
failure
(
String
.
valueOf
(
HaoBanErrCode
.
ERR_6
.
getCode
()),
HaoBanErrCode
.
ERR_6
.
getMsg
());
return
RestResponse
.
failure
(
String
.
valueOf
(
HaoBanErrCode
.
ERR_6
.
getCode
()),
HaoBanErrCode
.
ERR_6
.
getMsg
());
}
}
String
phoneNumber
=
staffDTO
.
getPhoneNumber
();
if
(
StringUtils
.
isBlank
(
phoneNumber
))
{
return
RestResponse
.
failure
(
String
.
valueOf
(
HaoBanErrCode
.
ERR_600002
.
getCode
()),
HaoBanErrCode
.
ERR_600002
.
getMsg
());
}
//登录和刷新token兼容
//登录和刷新token兼容
String
headerToken
=
AuthRequestWellDoneUtil
.
getHeaderToken
();
String
headerToken
=
AuthRequestWellDoneUtil
.
getHeaderToken
();
if
(
StringUtils
.
isNotBlank
(
headerToken
))
{
if
(
StringUtils
.
isNotBlank
(
headerToken
))
{
...
@@ -200,14 +204,14 @@ public class WxEnterpriseInfoController extends WebBaseController {
...
@@ -200,14 +204,14 @@ public class WxEnterpriseInfoController extends WebBaseController {
Map
<
String
,
String
>
map
=
new
HashMap
<>();
Map
<
String
,
String
>
map
=
new
HashMap
<>();
map
.
put
(
"staffId"
,
staffId
);
map
.
put
(
"staffId"
,
staffId
);
map
.
put
(
"wxEnterpriseId"
,
staffDTO
.
getWxEnterpriseId
());
map
.
put
(
"wxEnterpriseId"
,
staffDTO
.
getWxEnterpriseId
());
map
.
put
(
"phoneNumber"
,
staffDTO
.
getPhoneNumber
()
);
map
.
put
(
"phoneNumber"
,
phoneNumber
);
String
token
=
JwtUtil
.
genToken
(
map
);
String
token
=
JwtUtil
.
genToken
(
map
);
AuthRequestWellDoneUtil
.
setAppLoginUser
(
staffId
,
token
);
AuthRequestWellDoneUtil
.
setAppLoginUser
(
staffId
,
token
);
StaffLoginDTO
staffLoginDTO
=
new
StaffLoginDTO
();
StaffLoginDTO
staffLoginDTO
=
new
StaffLoginDTO
();
BeanUtils
.
copyProperties
(
staffLoginQO
,
staffLoginDTO
);
BeanUtils
.
copyProperties
(
staffLoginQO
,
staffLoginDTO
);
staffLoginDTO
.
setStaffIp
(
IPAddressUtil
.
getIpAddress
(
request
));
staffLoginDTO
.
setStaffIp
(
IPAddressUtil
.
getIpAddress
(
request
));
staffDTO
.
setWxEnterpriseId
(
staffDTO
.
getWxEnterpriseId
());
staffDTO
.
setWxEnterpriseId
(
staffDTO
.
getWxEnterpriseId
());
staffDTO
.
setPhoneNumber
(
staffDTO
.
getPhoneNumber
()
);
staffDTO
.
setPhoneNumber
(
phoneNumber
);
staffDTO
.
setWxUserId
(
staffDTO
.
getWxUserId
());
staffDTO
.
setWxUserId
(
staffDTO
.
getWxUserId
());
wxEnterpriseApiService
.
wellDoneLogin
(
staffLoginDTO
);
wxEnterpriseApiService
.
wellDoneLogin
(
staffLoginDTO
);
return
RestResponse
.
successResult
(
token
);
return
RestResponse
.
successResult
(
token
);
...
...
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/errCode/HaoBanErrCode.java
View file @
7f20b3b2
...
@@ -190,7 +190,7 @@ public enum HaoBanErrCode {
...
@@ -190,7 +190,7 @@ public enum HaoBanErrCode {
ERR_500001
(
500001
,
"该企业没关联好办"
),
ERR_500001
(
500001
,
"该企业没关联好办"
),
ERR_500003
(
500003
,
"企业corpid不对应,需要重新登录传code"
),
ERR_500003
(
500003
,
"企业corpid不对应,需要重新登录传code"
),
ERR_600001
(
600001
,
"成员不存在,请联系管理员后台授权通讯录权限"
),
ERR_600001
(
600001
,
"成员不存在,请联系管理员后台授权通讯录权限"
),
ERR_600002
(
600002
,
"
无手机号
"
),
ERR_600002
(
600002
,
"
未获取到成员手机号,请同步通讯录
"
),
ERR_600003
(
600003
,
"未获取成员openid"
),
ERR_600003
(
600003
,
"未获取成员openid"
),
ERR_10004
(
10004
,
"成员名称不能为空"
),
ERR_10004
(
10004
,
"成员名称不能为空"
),
...
...
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