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
1
Merge Requests
1
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
a4f52f2c
Commit
a4f52f2c
authored
Aug 11, 2022
by
徐高华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
区分加密不加密userid
parent
2211fc3d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
+10
-7
WxEnterpriseController.java
.../haoban/manage/web/controller/WxEnterpriseController.java
+10
-7
No files found.
haoban-manage3-web/src/main/java/com/gic/haoban/manage/web/controller/WxEnterpriseController.java
View file @
a4f52f2c
...
...
@@ -325,7 +325,7 @@ public class WxEnterpriseController extends WebBaseController {
return
resultResponse
(
HaoBanErrCode
.
ERR_10012
);
}
wxSecretKey
=
wxSecretKey
.
trim
();
String
res
=
qywxUserApiService
.
listSelfExternalUserid
(
qwDTO
.
getThirdCorpid
(),
wxSecretKey
,
getWxUserId
(
wxEnterpriseId
,
login
));
String
res
=
qywxUserApiService
.
listSelfExternalUserid
(
qwDTO
.
getThirdCorpid
(),
wxSecretKey
,
getWxUserId
(
wxEnterpriseId
,
login
,
qwDTO
));
logger
.
info
(
"【保存联系人key】res={}"
,
res
);
SecretSettingDTO
secretSetting
=
wxEnterpriseApiService
.
getSecretSetting
(
wxEnterpriseId
,
SecretTypeEnum
.
CONTACT_CUSTOMER
.
getVal
(),
null
);
if
(
null
==
secretSetting
)
{
...
...
@@ -367,7 +367,7 @@ public class WxEnterpriseController extends WebBaseController {
secretSetting
=
new
SecretSettingDTO
();
}
WxEnterpriseQwDTO
qwDTO
=
this
.
wxEnterpriseApiService
.
getQwInfo
(
wxEnterpriseId
)
;
UserDTO
user
=
qywxUserApiService
.
getSelfWorkWxUser
(
qwDTO
.
getMemberCorpid
(),
memberSecret
,
getWxUserId
(
wxEnterpriseId
,
login
));
UserDTO
user
=
qywxUserApiService
.
getSelfWorkWxUser
(
qwDTO
.
getMemberCorpid
(),
memberSecret
,
getWxUserId
(
wxEnterpriseId
,
login
,
qwDTO
));
secretSetting
.
setSecretType
(
SecretTypeEnum
.
MEMBER_WAPP
.
getVal
());
secretSetting
.
setSecretName
(
secretName
);
secretSetting
.
setEnterpriseId
(
enterpriseId
);
...
...
@@ -385,16 +385,19 @@ public class WxEnterpriseController extends WebBaseController {
}
}
private
String
getWxUserId
(
String
wxEnterpriseId
,
WebLoginDTO
loginDTO
)
{
private
String
getWxUserId
(
String
wxEnterpriseId
,
WebLoginDTO
loginDTO
,
WxEnterpriseQwDTO
qwDTO
)
{
if
(
loginDTO
!=
null
&&
(!
StringUtils
.
isEmpty
(
loginDTO
.
getStaffId
())))
{
String
staffId
=
loginDTO
.
getStaffId
()
;
StaffDTO
dto
=
this
.
staffApiService
.
selectById
(
staffId
)
;
if
(
null
!=
dto
&&
StringUtils
.
isNotBlank
(
dto
.
getStaffId
()))
{
return
dto
.
getWxUserId
();
if
(
null
!=
dto
)
{
if
(
qwDTO
.
needOpenUserId3th
())
{
return
dto
.
getWxOpenUseId
()
;
}
else
{
return
dto
.
getWxUserId
();
}
}
}
StaffDTO
staffOne
=
staffApiService
.
getWxStaffOne
(
wxEnterpriseId
);
return
staffOne
.
getWxUserId
();
return
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