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
QianQiXiang
haoban-manage3.0
Commits
30bd2df8
Commit
30bd2df8
authored
Apr 14, 2021
by
fudahua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
授权绑定,授权门店列表,binlog
parent
4ee9c5a5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
2 deletions
+11
-2
WxEnterpriseRelatedApiServiceImpl.java
...e/service/out/impl/WxEnterpriseRelatedApiServiceImpl.java
+9
-0
TabHaobanStoreRangeMapper.xml
...e/src/main/resources/mapper/TabHaobanStoreRangeMapper.xml
+2
-2
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/WxEnterpriseRelatedApiServiceImpl.java
View file @
30bd2df8
...
@@ -12,6 +12,7 @@ import com.gic.haoban.common.utils.PageUtil;
...
@@ -12,6 +12,7 @@ import com.gic.haoban.common.utils.PageUtil;
import
com.gic.haoban.manage.api.dto.*
;
import
com.gic.haoban.manage.api.dto.*
;
import
com.gic.haoban.manage.service.entity.*
;
import
com.gic.haoban.manage.service.entity.*
;
import
com.gic.haoban.manage.service.service.StoreRangeService
;
import
com.gic.haoban.manage.service.service.StoreRangeService
;
import
com.google.common.collect.Sets
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.LogManager
;
...
@@ -270,6 +271,7 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
...
@@ -270,6 +271,7 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
//分组所在的企业map groupId->wxEnterpriseId
//分组所在的企业map groupId->wxEnterpriseId
Map
<
String
,
String
>
groupMap
=
groupInfoDTOS
.
stream
().
filter
(
tab
->
tab
.
getRelationType
()
==
1
)
Map
<
String
,
String
>
groupMap
=
groupInfoDTOS
.
stream
().
filter
(
tab
->
tab
.
getRelationType
()
==
1
)
.
collect
(
Collectors
.
toMap
(
tab
->
tab
.
getRelationId
(),
tab
->
tab
.
getWxEnterpriseId
()));
.
collect
(
Collectors
.
toMap
(
tab
->
tab
.
getRelationId
(),
tab
->
tab
.
getWxEnterpriseId
()));
Set
<
String
>
rightGroupIds
=
groupMap
.
keySet
();
// 获取所有门店信息
// 获取所有门店信息
...
@@ -282,6 +284,13 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
...
@@ -282,6 +284,13 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
Map
<
String
,
Set
<
String
>>
storeGroupChainMap
=
storeGroupList
.
stream
().
collect
(
Collectors
.
toMap
(
dto
->
dto
.
getStoreGroupId
(),
Map
<
String
,
Set
<
String
>>
storeGroupChainMap
=
storeGroupList
.
stream
().
collect
(
Collectors
.
toMap
(
dto
->
dto
.
getStoreGroupId
(),
dto
->
Arrays
.
stream
(
dto
.
getStoreGroupChain
().
split
(
"-"
)).
filter
(
str
->
StringUtils
.
isNotBlank
(
str
)).
collect
(
Collectors
.
toSet
())));
dto
->
Arrays
.
stream
(
dto
.
getStoreGroupChain
().
split
(
"-"
)).
filter
(
str
->
StringUtils
.
isNotBlank
(
str
)).
collect
(
Collectors
.
toSet
())));
storeMapByGroupId
.
forEach
((
groupId
,
storeIds
)
->
{
Set
<
String
>
chainGroupIds
=
storeGroupChainMap
.
get
(
groupId
);
Sets
.
SetView
<
String
>
midGroupIds
=
Sets
.
intersection
(
chainGroupIds
,
rightGroupIds
);
if
(
CollectionUtils
.
isEmpty
(
midGroupIds
))
{
}
});
return
false
;
return
false
;
}
}
...
...
haoban-manage3-service/src/main/resources/mapper/TabHaobanStoreRangeMapper.xml
View file @
30bd2df8
...
@@ -144,7 +144,7 @@
...
@@ -144,7 +144,7 @@
status_flag = 0,
status_flag = 0,
update_time = now()
update_time = now()
where
where
where
enterprise_id = #{enterpriseId,jdbcType=VARCHAR}
enterprise_id = #{enterpriseId,jdbcType=VARCHAR}
and wx_enterprise_id=#{wxEnterpriseId}
and wx_enterprise_id=#{wxEnterpriseId}
and status_flag =1
and status_flag =1
</update>
</update>
...
@@ -155,7 +155,7 @@
...
@@ -155,7 +155,7 @@
status_flag = 0,
status_flag = 0,
update_time = now()
update_time = now()
where
where
where
enterprise_id = #{enterpriseId,jdbcType=VARCHAR}
enterprise_id = #{enterpriseId,jdbcType=VARCHAR}
and relation_id=#{relationId}
and relation_id=#{relationId}
and status_flag =1
and status_flag =1
</update>
</update>
...
...
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