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
37b16bc0
Commit
37b16bc0
authored
Apr 18, 2023
by
徐高华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
导购解绑
parent
94207e58
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
StaffClerkRelationServiceImpl.java
...e/service/service/impl/StaffClerkRelationServiceImpl.java
+12
-0
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/impl/StaffClerkRelationServiceImpl.java
View file @
37b16bc0
...
...
@@ -116,12 +116,18 @@ public class StaffClerkRelationServiceImpl implements StaffClerkRelationService
logger
.
info
(
"老的绑定关联不存在,oldClerkId={}"
,
oldClerkId
);
return
true
;
}
// 如果是区经
if
(
clerkRelation
.
getManageFlag
()==
1
)
{
this
.
mapper
.
changeStatusByClerkId
(
oldClerkId
,
0
);
return
true
;
}
wxEnterpriseId
=
clerkRelation
.
getWxEnterpriseId
()
;
String
enterpriseId
=
clerkRelation
.
getEnterpriseId
();
logger
.
info
(
"当前删除换绑的商户={},{}"
,
enterpriseId
,
wxEnterpriseId
);
String
staffId
=
clerkRelation
.
getStaffId
()
;
String
storeId
=
clerkRelation
.
getStoreId
()
;
boolean
needFlush
=
false
;
boolean
delFlag
=
true
;
if
(
StringUtils
.
isEmpty
(
newClerkId
))
{
// 成员关联的门店
List
<
StaffClerkRelationDTO
>
relationList
=
this
.
listByStaffId
(
wxEnterpriseId
,
staffId
)
;
...
...
@@ -146,6 +152,7 @@ public class StaffClerkRelationServiceImpl implements StaffClerkRelationService
if
(
mainStoreEnterpriseId
.
equals
(
enterpriseId
))
{
// 删除关联关系
this
.
mapper
.
changeStatusByClerkId
(
oldClerkId
,
0
);
delFlag
=
false
;
TabHaobanClerkMainStoreRelated
mainStoreRelation
=
this
.
clerkMainStoreRelatedService
.
getMainStoreByStaffId
(
staffId
,
wxEnterpriseId
,
storeIdList
)
;
String
newStoreId
=
mainStoreRelation
.
getStoreId
()
;
StaffClerkRelationDTO
mainClerk
=
this
.
getOneBindByStoreId
(
staffId
,
newStoreId
)
;
...
...
@@ -156,6 +163,7 @@ public class StaffClerkRelationServiceImpl implements StaffClerkRelationService
}
else
{
// 删除关联关系
this
.
mapper
.
changeStatusByClerkId
(
oldClerkId
,
0
);
delFlag
=
false
;
TabHaobanClerkMainStoreRelated
mainStore
=
this
.
clerkMainStoreRelatedService
.
getMainStoreByStaffId
(
staffId
,
wxEnterpriseId
,
storeIdList
)
;
String
newStoreId
=
mainStore
.
getStoreId
()
;
StaffClerkRelationDTO
mainClerk
=
this
.
getOneBindByStoreId
(
staffId
,
newStoreId
)
;
...
...
@@ -164,6 +172,10 @@ public class StaffClerkRelationServiceImpl implements StaffClerkRelationService
}
}
}
// 删除关联关系
if
(
delFlag
)
{
this
.
mapper
.
changeStatusByClerkId
(
oldClerkId
,
0
);
}
if
(
StringUtils
.
isNotBlank
(
newClerkId
))
{
List
<
String
>
memberIdList
=
this
.
externalClerkRelatedMapper
.
listByClerkId
(
staffId
,
oldClerkId
)
;
this
.
externalClerkRelatedService
.
updateClerkInfo
(
staffId
,
oldClerkId
,
newClerkId
)
;
...
...
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