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
8de2644d
Commit
8de2644d
authored
Jan 06, 2023
by
徐高华
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/社群' into 'master'
Feature/社群 See merge request
!845
parents
fa00f428
0aa4f720
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
5 deletions
+30
-5
WxEnterpriseInfoController.java
...ban/manage/web/controller/WxEnterpriseInfoController.java
+30
-5
No files found.
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/controller/WxEnterpriseInfoController.java
View file @
8de2644d
...
...
@@ -45,6 +45,7 @@ import com.gic.haoban.common.anno.IgnoreLogin;
import
com.gic.haoban.common.utils.EntityUtil
;
import
com.gic.haoban.common.utils.HaobanResponse
;
import
com.gic.haoban.manage.api.dto.ClerkMainStoreRelatedDTO
;
import
com.gic.haoban.manage.api.dto.EnterpriseDetailDTO
;
import
com.gic.haoban.manage.api.dto.ExternalClerkRelatedDTO
;
import
com.gic.haoban.manage.api.dto.ExternalUserDTO
;
import
com.gic.haoban.manage.api.dto.MemberStoreDTO
;
...
...
@@ -79,6 +80,7 @@ import com.gic.haoban.manage.web.vo.MemberSendMessageVo;
import
com.gic.haoban.manage.web.vo.StoreMemberVO
;
import
com.gic.haoban.manage.web.vo.WellDoneLoginInfoVO
;
import
com.gic.member.api.service.MemberOpenCardBusinessService
;
import
com.gic.redis.data.util.RedisUtil
;
import
com.gic.wechat.api.dto.qywx.UserDTO
;
import
com.gic.wechat.api.service.qywx.QywxCorpApiService
;
import
com.gic.wechat.api.service.qywx.QywxUserApiService
;
...
...
@@ -149,6 +151,26 @@ public class WxEnterpriseInfoController extends WebBaseController {
}
String
userId
=
user
.
getUserid
();
String
corpId
=
user
.
getCorpid
();
WxEnterpriseDTO
wxEnterprise
=
wxEnterpriseApiService
.
getEnterpriseBycorpId
(
corpId
);
boolean
testFlag
=
false
;
if
(
null
==
wxEnterprise
)
{
logger
.
info
(
"通过corpid查不到企业corpid={}"
,
corpId
);
testFlag
=
true
;
}
if
(!
testFlag
)
{
List
<
EnterpriseDetailDTO
>
relationList
=
wxEnterpriseRelatedApiService
.
listEnterpriseByWxEnterpriseId
(
wxEnterprise
.
getWxEnterpriseId
());
if
(
CollectionUtils
.
isEmpty
(
relationList
))
{
logger
.
info
(
"企业未关联gic商户,corpid={}"
,
corpId
);
testFlag
=
true
;
}
}
if
(
testFlag
)
{
Object
testAccount
=
RedisUtil
.
getCache
(
"haoban-test-account"
)
;
logger
.
info
(
"testAccount={}"
,
testAccount
);
if
(
null
!=
testAccount
)
{
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
JSON
.
parseObject
((
String
)
testAccount
));
}
}
// 判断好办是否到期
ServiceResponse
<
Boolean
>
resp
=
this
.
wxEnterpriseApiService
.
isStopHaoban
(
corpId
);
if
(!
resp
.
isSuccess
())
{
...
...
@@ -157,15 +179,18 @@ public class WxEnterpriseInfoController extends WebBaseController {
response
.
setMessage
(
resp
.
getMessage
());
return
response
;
}
WxEnterpriseDTO
enterprise
=
wxEnterpriseApiService
.
getEnterpriseBycorpId
(
corpId
);
StaffDTO
loginStaff
=
null
;
if
(
e
nterprise
!=
null
)
{
loginStaff
=
staffApiService
.
getByUserIdAndReflushWhenNoPhone
(
userId
,
e
nterprise
.
getWxEnterpriseId
());
if
(
wxE
nterprise
!=
null
)
{
loginStaff
=
staffApiService
.
getByUserIdAndReflushWhenNoPhone
(
userId
,
wxE
nterprise
.
getWxEnterpriseId
());
if
(
loginStaff
==
null
)
{
staffApiService
.
wxGetAdd
(
userId
,
e
nterprise
.
getWxEnterpriseId
());
loginStaff
=
staffApiService
.
selectByUserIdAndEnterpriseId
(
userId
,
e
nterprise
.
getWxEnterpriseId
());
staffApiService
.
wxGetAdd
(
userId
,
wxE
nterprise
.
getWxEnterpriseId
());
loginStaff
=
staffApiService
.
selectByUserIdAndEnterpriseId
(
userId
,
wxE
nterprise
.
getWxEnterpriseId
());
}
}
if
(
loginStaff
==
null
)
{
logger
.
info
(
"游客用户"
);
WellDoneLoginInfoVO
wellDoneLoginInfoVo
=
new
WellDoneLoginInfoVO
();
...
...
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