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
0d621fc3
Commit
0d621fc3
authored
Jul 21, 2022
by
songyinghui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 活码分组到企业微信
parent
9437255c
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
22 additions
and
13 deletions
+22
-13
TabHaobanHmQrcodeMapper.java
...manage/service/dao/mapper/hm/TabHaobanHmQrcodeMapper.java
+2
-2
HmQrcodeService.java
...gic/haoban/manage/service/service/hm/HmQrcodeService.java
+2
-3
HmQrcodeServiceImpl.java
...n/manage/service/service/hm/impl/HmQrcodeServiceImpl.java
+4
-4
HmGroupApiServiceImpl.java
...ge/service/service/out/impl/hm/HmGroupApiServiceImpl.java
+4
-3
TabHaobanHmQrcodeMapper.xml
.../src/main/resources/mapper/hm/TabHaobanHmQrcodeMapper.xml
+10
-1
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/dao/mapper/hm/TabHaobanHmQrcodeMapper.java
View file @
0d621fc3
...
...
@@ -168,7 +168,7 @@ public interface TabHaobanHmQrcodeMapper {
* @author mozhu
* @date 2022-07-12 17:39:12
*/
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
@Param
(
"enterpriseId"
)
String
enterpriseId
,
@Param
(
"groupIds"
)
List
<
Long
>
groupIds
,
@Param
(
"hmIds"
)
List
<
String
>
hmIds
);
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
@Param
(
"
wxEnterpriseId"
)
String
wxEnterpriseId
,
@Param
(
"
enterpriseId"
)
String
enterpriseId
,
@Param
(
"groupIds"
)
List
<
Long
>
groupIds
,
@Param
(
"hmIds"
)
List
<
String
>
hmIds
);
/**
* 获取总数
...
...
@@ -178,7 +178,7 @@ public interface TabHaobanHmQrcodeMapper {
* @author mozhu
* @date 2022-07-12 15:10:09
*/
int
getTotalByEnterpriseId
(
@Param
(
"enterpriseId"
)
String
enterpriseId
,
@Param
(
"hmIds"
)
List
<
String
>
hmIds
);
int
getTotalByEnterpriseId
(
@Param
(
"
wxEnterpriseId"
)
String
wxEnterpriseId
,
@Param
(
"
enterpriseId"
)
String
enterpriseId
,
@Param
(
"hmIds"
)
List
<
String
>
hmIds
);
/**
* 批量修改 活码所属分组
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/hm/HmQrcodeService.java
View file @
0d621fc3
package
com
.
gic
.
haoban
.
manage
.
service
.
service
.
hm
;
import
com.gic.api.base.commons.Page
;
import
com.gic.api.base.commons.ServiceResponse
;
import
com.gic.haoban.manage.api.dto.qdto.hm.HmQrcodeListQDTO
;
import
com.gic.haoban.manage.api.dto.qdto.hm.HmQrcodeQDTO
;
import
com.gic.haoban.manage.service.pojo.bo.hm.HmQrcodeBO
;
...
...
@@ -157,7 +156,7 @@ public interface HmQrcodeService {
* @author mozhu
* @date 2022-07-12 17:38:43
*/
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
String
enterpriseId
,
List
<
Long
>
groupIds
,
List
<
String
>
hmIds
);
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
String
wxEnterpriseId
,
String
enterpriseId
,
List
<
Long
>
groupIds
,
List
<
String
>
hmIds
);
/**
* 获取总数
...
...
@@ -167,7 +166,7 @@ public interface HmQrcodeService {
* @author mozhu
* @date 2022-07-12 15:08:35
*/
int
getTotalByEnterpriseId
(
String
enterpriseId
,
List
<
String
>
hmIds
);
int
getTotalByEnterpriseId
(
String
wxEnterpriseId
,
String
enterpriseId
,
List
<
String
>
hmIds
);
/**
* 批量修改活码分组
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/hm/impl/HmQrcodeServiceImpl.java
View file @
0d621fc3
...
...
@@ -123,13 +123,13 @@ public class HmQrcodeServiceImpl implements HmQrcodeService {
}
@Override
public
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
String
enterpriseId
,
List
<
Long
>
groupIds
,
List
<
String
>
hmIds
)
{
return
tabHaobanHmQrcodeMapper
.
getGroupIdNumByEnterpriseId
(
enterpriseId
,
groupIds
,
hmIds
);
public
List
<
HmQrcodeGroupNumBO
>
getGroupIdNumByEnterpriseId
(
String
wxEnterpriseId
,
String
enterpriseId
,
List
<
Long
>
groupIds
,
List
<
String
>
hmIds
)
{
return
tabHaobanHmQrcodeMapper
.
getGroupIdNumByEnterpriseId
(
wxEnterpriseId
,
enterpriseId
,
groupIds
,
hmIds
);
}
@Override
public
int
getTotalByEnterpriseId
(
String
enterpriseId
,
List
<
String
>
hmIds
)
{
return
tabHaobanHmQrcodeMapper
.
getTotalByEnterpriseId
(
enterpriseId
,
hmIds
);
public
int
getTotalByEnterpriseId
(
String
wxEnterpriseId
,
String
enterpriseId
,
List
<
String
>
hmIds
)
{
return
tabHaobanHmQrcodeMapper
.
getTotalByEnterpriseId
(
wxEnterpriseId
,
enterpriseId
,
hmIds
);
}
@Override
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/hm/HmGroupApiServiceImpl.java
View file @
0d621fc3
...
...
@@ -105,7 +105,6 @@ public class HmGroupApiServiceImpl implements HmGroupApiService {
HmGroupInfoQO
groupInfoQo
=
new
HmGroupInfoQO
();
BeanUtils
.
copyProperties
(
groupQueryDTO
,
groupInfoQo
);
groupInfoQo
.
setWxEnterpriseId
(
null
);
groupInfoQo
.
setStatus
(
HmGroupStatus
.
ENABLE
.
getCode
());
Page
<
HmGroupSettingBO
>
groupSettingPage
=
groupService
.
queryGroupSettingList
(
groupInfoQo
);
...
...
@@ -127,9 +126,10 @@ public class HmGroupApiServiceImpl implements HmGroupApiService {
HmQrcodeListQDTO
hmQrcodeListQDTO
=
new
HmQrcodeListQDTO
();
hmQrcodeListQDTO
.
setEnterpriseId
(
groupQueryDTO
.
getEnterpriseId
());
hmQrcodeListQDTO
.
setStoreId
(
storeList
);
hmQrcodeListQDTO
.
setWxEnterpriseId
(
groupQueryDTO
.
getWxEnterpriseId
());
hmIds
=
qrcodeService
.
listHmIdForIndex
(
hmQrcodeListQDTO
);
}
List
<
HmQrcodeGroupNumBO
>
qrcodeGroupNumBoList
=
qrcodeService
.
getGroupIdNumByEnterpriseId
(
groupQueryDTO
.
getEnterpriseId
(),
groupIds
,
hmIds
);
List
<
HmQrcodeGroupNumBO
>
qrcodeGroupNumBoList
=
qrcodeService
.
getGroupIdNumByEnterpriseId
(
groupQueryDTO
.
get
WxEnterpriseId
(),
groupQueryDTO
.
get
EnterpriseId
(),
groupIds
,
hmIds
);
if
(
CollectionUtils
.
isNotEmpty
(
qrcodeGroupNumBoList
))
{
qrcodeGroupNumMap
=
qrcodeGroupNumBoList
.
stream
()
.
collect
(
Collectors
.
toMap
(
HmQrcodeGroupNumBO:
:
getHmGroupId
,
HmQrcodeGroupNumBO:
:
getNum
,
(
v1
,
v2
)
->
v1
));
...
...
@@ -193,11 +193,12 @@ public class HmGroupApiServiceImpl implements HmGroupApiService {
HmQrcodeListQDTO
hmQrcodeListQDTO
=
new
HmQrcodeListQDTO
();
hmQrcodeListQDTO
.
setEnterpriseId
(
enterpriseId
);
hmQrcodeListQDTO
.
setStoreId
(
storeList
);
hmQrcodeListQDTO
.
setWxEnterpriseId
(
wxEnterpriseId
);
hmIds
=
qrcodeService
.
listHmIdForIndex
(
hmQrcodeListQDTO
);
log
.
info
(
"导购拥有的活码权限列表:{}"
,
JSON
.
toJSONString
(
hmIds
));
}
}
int
totalReferCount
=
qrcodeService
.
getTotalByEnterpriseId
(
enterpriseId
,
hmIds
);
int
totalReferCount
=
qrcodeService
.
getTotalByEnterpriseId
(
wxEnterpriseId
,
enterpriseId
,
hmIds
);
return
ServiceResponse
.
success
(
totalReferCount
);
}
...
...
haoban-manage3-service/src/main/resources/mapper/hm/TabHaobanHmQrcodeMapper.xml
View file @
0d621fc3
...
...
@@ -329,7 +329,10 @@
<select
id=
"listHmIdForIndex"
resultType=
"String"
parameterType=
"com.gic.haoban.manage.api.dto.qdto.hm.HmQrcodeListQDTO"
>
select distinct(a.hm_id)
from tab_haoban_hm_qrcode a left join tab_haoban_hm_clerk_relation b on a.hm_id = b.hm_id and b.status = 1
where a.enterprise_id = #{enterpriseId} and a.status_flag != 0
where a.enterprise_id = #{enterpriseId} and a.status_flag != 0
<if
test=
"wxEnterpriseId != null and wxEnterpriseId != ''"
>
and a.wx_enterprise_id = #{wxEnterpriseId}
</if>
<if
test=
"null != hmSelect and '' != hmSelect "
>
and (a.hm_code=#{hmSelect} or a.name like '%${hmSelect}%' or a.creator_name like '%${hmSelect}%' )
</if>
...
...
@@ -371,6 +374,9 @@
from tab_haoban_hm_qrcode
where status_flag != 0
and enterprise_id = #{enterpriseId}
<if
test=
"wxEnterpriseId != null and wxEnterpriseId != ''"
>
and wx_enterprise_id = #{wxEnterpriseId}
</if>
<if
test=
"groupIds != null and groupIds.size > 0"
>
and hm_group_id IN
<foreach
collection=
"groupIds"
item=
"id"
index=
"index"
open=
"("
close=
")"
separator=
","
>
...
...
@@ -391,6 +397,9 @@
from tab_haoban_hm_qrcode
where status_flag != 0
and enterprise_id = #{enterpriseId}
<if
test=
"wxEnterpriseId != null and wxEnterpriseId != ''"
>
and wx_enterprise_id = #{wxEnterpriseId}
</if>
<if
test=
"hmIds != null and hmIds.size > 0"
>
and hm_id in
<foreach
collection=
"hmIds"
open=
"("
close=
")"
separator=
","
item=
"hmId"
>
...
...
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