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
52c46592
Commit
52c46592
authored
Apr 18, 2024
by
徐高华
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/xgh/2024权限调整' into 'developer'
Feature/xgh/2024权限调整 See merge request
!1700
parents
4feef80a
40a774c2
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
175 additions
and
134 deletions
+175
-134
HaobanCommonMQApiService.java
...c/haoban/manage/api/service/HaobanCommonMQApiService.java
+2
-0
HaobanRoleApiService.java
.../haoban/manage/api/service/role/HaobanRoleApiService.java
+2
-0
TabHaobanMenu.java
.../gic/haoban/manage/service/entity/role/TabHaobanMenu.java
+0
-46
HaobanMenuBO.java
.../gic/haoban/manage/service/pojo/bo/role/HaobanMenuBO.java
+0
-46
HaobanCommonMQApiServiceImpl.java
...ervice/service/out/impl/HaobanCommonMQApiServiceImpl.java
+8
-0
HaobanRoleApiServiceImpl.java
...rvice/service/out/impl/role/HaobanRoleApiServiceImpl.java
+58
-11
HaobanMenuService.java
...haoban/manage/service/service/role/HaobanMenuService.java
+2
-0
HaobanMenuServiceImpl.java
...nage/service/service/role/impl/HaobanMenuServiceImpl.java
+97
-4
dubbo-haoban-manage-service.xml
...ervice/src/main/resources/dubbo-haoban-manage-service.xml
+2
-0
TabHaobanMenuMapper.xml
...ce/src/main/resources/mapper/role/TabHaobanMenuMapper.xml
+2
-25
WxStaffController.java
...m/gic/haoban/manage/web/controller/WxStaffController.java
+2
-2
No files found.
haoban-manage3-api/src/main/java/com/gic/haoban/manage/api/service/HaobanCommonMQApiService.java
View file @
52c46592
...
...
@@ -34,6 +34,8 @@ public interface HaobanCommonMQApiService {
public
void
memberEventDel
(
String
params
)
;
// 会员扫码关注
public
void
memberEventWechat
(
String
params
)
;
// 服务开通事件
public
void
serviceOpenOffEvent
(
String
params
)
;
}
haoban-manage3-api/src/main/java/com/gic/haoban/manage/api/service/role/HaobanRoleApiService.java
View file @
52c46592
...
...
@@ -44,6 +44,8 @@ public interface HaobanRoleApiService {
*/
ServiceResponse
<
HaobanRoleDTO
>
getMenuByWxEnterpriseIdAndClerkType
(
String
wxEnterpriseId
,
Integer
clerkType
,
Integer
systemFlag
);
ServiceResponse
<
HaobanRoleDTO
>
getMenuByWxEnterpriseIdAndClerkType
(
String
wxEnterpriseId
,
Integer
clerkType
,
Integer
systemFlag
,
String
enterpriseId
);
/**
*
* 默认生成好办小程序权限
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/entity/role/TabHaobanMenu.java
View file @
52c46592
...
...
@@ -57,52 +57,6 @@ public class TabHaobanMenu implements Serializable {
private
int
authControl
;
private
String
btnCodeRel
;
private
String
appCode
;
private
Integer
funType
;
private
Integer
noOpenFlag
;
private
Integer
expireFlag
;
private
String
appVersions
;
public
String
getAppCode
()
{
return
appCode
;
}
public
void
setAppCode
(
String
appCode
)
{
this
.
appCode
=
appCode
;
}
public
Integer
getFunType
()
{
return
funType
;
}
public
void
setFunType
(
Integer
funType
)
{
this
.
funType
=
funType
;
}
public
Integer
getNoOpenFlag
()
{
return
noOpenFlag
;
}
public
void
setNoOpenFlag
(
Integer
noOpenFlag
)
{
this
.
noOpenFlag
=
noOpenFlag
;
}
public
Integer
getExpireFlag
()
{
return
expireFlag
;
}
public
void
setExpireFlag
(
Integer
expireFlag
)
{
this
.
expireFlag
=
expireFlag
;
}
public
String
getAppVersions
()
{
return
appVersions
;
}
public
void
setAppVersions
(
String
appVersions
)
{
this
.
appVersions
=
appVersions
;
}
public
int
getAuthControl
()
{
return
authControl
;
}
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/pojo/bo/role/HaobanMenuBO.java
View file @
52c46592
...
...
@@ -64,52 +64,6 @@ public class HaobanMenuBO implements Serializable {
private
int
authControl
;
private
String
btnCodeRel
;
private
String
appCode
;
private
Integer
funType
;
private
Integer
noOpenFlag
;
private
Integer
expireFlag
;
private
String
appVersions
;
public
String
getAppCode
()
{
return
appCode
;
}
public
void
setAppCode
(
String
appCode
)
{
this
.
appCode
=
appCode
;
}
public
Integer
getFunType
()
{
return
funType
;
}
public
void
setFunType
(
Integer
funType
)
{
this
.
funType
=
funType
;
}
public
Integer
getNoOpenFlag
()
{
return
noOpenFlag
;
}
public
void
setNoOpenFlag
(
Integer
noOpenFlag
)
{
this
.
noOpenFlag
=
noOpenFlag
;
}
public
Integer
getExpireFlag
()
{
return
expireFlag
;
}
public
void
setExpireFlag
(
Integer
expireFlag
)
{
this
.
expireFlag
=
expireFlag
;
}
public
String
getAppVersions
()
{
return
appVersions
;
}
public
void
setAppVersions
(
String
appVersions
)
{
this
.
appVersions
=
appVersions
;
}
public
int
getAuthControl
()
{
return
authControl
;
}
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/HaobanCommonMQApiServiceImpl.java
View file @
52c46592
...
...
@@ -8,6 +8,7 @@ import com.gic.haoban.manage.service.service.StaffClerkRelationService;
import
com.gic.commons.util.StringUtil
;
import
com.gic.haoban.manage.api.dto.MemberUnionidWechatAccountQDTO
;
import
com.gic.haoban.manage.api.service.ExternalClerkRelatedApiService
;
import
com.gic.haoban.manage.service.service.role.HaobanMenuService
;
import
com.gic.haoban.manage.service.util.EventUtils
;
import
com.gic.member.api.dto.MemberInfoChangeNotifyDTO
;
import
com.gic.member.api.dto.event.wechat.WeChatOfficialAccountEventParam
;
...
...
@@ -50,6 +51,8 @@ public class HaobanCommonMQApiServiceImpl implements HaobanCommonMQApiService {
private
ExternalClerkRelatedApiService
externalClerkRelatedApiService
;
@Autowired
private
StaffClerkRelationService
staffClerkRelationService
;
@Autowired
private
HaobanMenuService
haobanMenuService
;
@Override
public
void
putCommonMessage
(
CommonMQDTO
dto
)
{
...
...
@@ -237,4 +240,9 @@ public class HaobanCommonMQApiServiceImpl implements HaobanCommonMQApiService {
log
.
error
(
"通知好办失败"
,
e
);
}
}
@Override
public
void
serviceOpenOffEvent
(
String
params
)
{
this
.
haobanMenuService
.
saveMenuFromGicEvent
(
params
);
}
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/role/HaobanRoleApiServiceImpl.java
View file @
52c46592
...
...
@@ -238,22 +238,73 @@ public class HaobanRoleApiServiceImpl implements HaobanRoleApiService {
@Override
public
ServiceResponse
<
HaobanRoleDTO
>
getMenuByWxEnterpriseIdAndClerkType
(
String
wxEnterpriseId
,
Integer
clerkType
,
Integer
systemFlag
)
{
HaobanRoleBO
haobanRoleBO
=
haobanRoleService
.
getByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
systemFlag
);
if
(
haobanRoleBO
!=
null
)
{
List
<
String
>
menuCodes
=
haobanRoleMenuService
.
getByWxEnterpriseIdAndRoleId
(
wxEnterpriseId
,
haobanRoleBO
.
getRoleId
());
return
this
.
getMenuByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
systemFlag
,
null
)
;
}
@Override
public
ServiceResponse
<
HaobanRoleDTO
>
getMenuByWxEnterpriseIdAndClerkType
(
String
wxEnterpriseId
,
Integer
clerkType
,
Integer
systemFlag
,
String
enterpriseId
)
{
logger
.
info
(
"查询好办小程序权限={},{},{},{}"
,
systemFlag
,
wxEnterpriseId
,
clerkType
,
enterpriseId
);
// 查询商户普通权限是,需要过滤超管没有的
HaobanRoleBO
superRoleBO
=
haobanRoleService
.
getByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
0
);
if
(
null
==
superRoleBO
)
{
return
ServiceResponse
.
failure
(
"9999"
,
"未配置运维权限"
)
;
}
List
<
HaobanMenuBO
>
allMenuList
=
haobanMenuService
.
getAllMenuList
();
// 添加关联的权限
Long
superRoleId
=
superRoleBO
.
getRoleId
()
;
List
<
String
>
superMenuCodeList
=
this
.
listRoleMenuCode
(
allMenuList
,
wxEnterpriseId
,
superRoleId
);
// 查询gic配置的权限
if
(
StringUtils
.
isNotBlank
(
enterpriseId
)
&&
!
"-1"
.
equals
(
enterpriseId
))
{
}
logger
.
info
(
"超管的权限={}"
,
superMenuCodeList
);
// 如果查询的后台的子管理员权限
HaobanRoleBO
subRoleBO
=
null
;
List
<
String
>
subMenuCodes
=
null
;
if
(
systemFlag
==
1
)
{
subRoleBO
=
haobanRoleService
.
getByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
1
);
if
(
null
==
subRoleBO
)
{
return
ServiceResponse
.
failure
(
"9999"
,
"未配置子管理员权限"
)
;
}
Long
subRoleId
=
subRoleBO
.
getRoleId
()
;
subMenuCodes
=
this
.
listRoleMenuCode
(
allMenuList
,
wxEnterpriseId
,
subRoleId
)
;
}
HaobanRoleBO
retBO
=
new
HaobanRoleBO
();
if
(
systemFlag
==
0
)
{
retBO
=
superRoleBO
;
retBO
.
setMenuCodes
(
superMenuCodeList
);
}
else
{
retBO
=
subRoleBO
;
List
<
String
>
subCodeList
=
new
ArrayList
<>()
;
for
(
String
subCode
:
subMenuCodes
)
{
if
(
superMenuCodeList
.
contains
(
subCode
))
{
subCodeList
.
add
(
subCode
)
;
}
}
retBO
.
setMenuCodes
(
subCodeList
);
}
List
<
HaobanMenuBO
>
haobanMenuList
=
new
ArrayList
<>()
;
Map
<
String
,
HaobanMenuBO
>
map
=
allMenuList
.
stream
().
collect
(
Collectors
.
toMap
(
HaobanMenuBO:
:
getMenuCode
,
o
->
o
,(
k1
,
k2
)->
k1
))
;
for
(
String
code
:
retBO
.
getMenuCodes
())
{
HaobanMenuBO
bo
=
map
.
get
(
code
)
;
if
(
null
!=
bo
)
{
haobanMenuList
.
add
(
bo
)
;
}
}
retBO
.
setMenuList
(
EntityUtil
.
changeEntityListNew
(
HaobanMenuDTO
.
class
,
haobanMenuList
));
return
ServiceResponse
.
success
(
EntityUtil
.
changeEntityNew
(
HaobanRoleDTO
.
class
,
retBO
));
}
private
List
<
String
>
listRoleMenuCode
(
List
<
HaobanMenuBO
>
allMenuList
,
String
wxEnterpriseId
,
Long
roleId
)
{
List
<
String
>
menuCodes
=
haobanRoleMenuService
.
getByWxEnterpriseIdAndRoleId
(
wxEnterpriseId
,
roleId
);
// 添加关联的权限
for
(
HaobanMenuBO
item
:
allMenuList
)
{
String
code
=
item
.
getMenuCode
()
;
// 开启的权限
if
(
menuCodes
.
contains
(
code
))
{
haobanMenuList
.
add
(
item
)
;
continue
;
}
// 无需授权的权限
if
(
0
==
item
.
getAuthControl
()
&&
StringUtils
.
isEmpty
(
item
.
getBtnCodeRel
()))
{
haobanMenuList
.
add
(
item
)
;
menuCodes
.
add
(
code
)
;
continue
;
}
...
...
@@ -261,15 +312,11 @@ public class HaobanRoleApiServiceImpl implements HaobanRoleApiService {
for
(
HaobanMenuBO
item
:
allMenuList
)
{
String
code
=
item
.
getBtnCodeRel
()
;
if
(
0
==
item
.
getAuthControl
()
&&
StringUtils
.
isNotEmpty
(
item
.
getBtnCodeRel
())
&&
menuCodes
.
contains
(
code
))
{
haobanMenuList
.
add
(
item
)
;
menuCodes
.
add
(
code
)
;
continue
;
}
}
haobanRoleBO
.
setMenuCodes
(
menuCodes
);
haobanRoleBO
.
setMenuList
(
EntityUtil
.
changeEntityListNew
(
HaobanMenuDTO
.
class
,
haobanMenuList
));
}
return
ServiceResponse
.
success
(
EntityUtil
.
changeEntityNew
(
HaobanRoleDTO
.
class
,
haobanRoleBO
));
return
menuCodes
;
}
@Override
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/role/HaobanMenuService.java
View file @
52c46592
...
...
@@ -95,4 +95,6 @@ public interface HaobanMenuService {
void
deleteAll
();
void
deleteByMenuCode
(
String
menuCode
)
;
void
saveMenuFromGicEvent
(
String
params
)
;
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/role/impl/HaobanMenuServiceImpl.java
View file @
52c46592
package
com
.
gic
.
haoban
.
manage
.
service
.
service
.
role
.
impl
;
import
com.alibaba.fastjson.JSONObject
;
import
com.gic.api.base.commons.ServiceResponse
;
import
com.gic.clerk.api.dto.right.MenuDTO
;
import
com.gic.clerk.api.dto.right.MenuListQDTO
;
import
com.gic.clerk.api.service.MenuApiService
;
import
com.gic.commons.util.EntityUtil
;
import
com.gic.commons.util.UniqueIdUtils
;
import
com.gic.haoban.manage.service.dao.mapper.WxEnterpriseRelatedMapper
;
import
com.gic.haoban.manage.service.dao.mapper.role.TabHaobanMenuMapper
;
import
com.gic.haoban.manage.service.dao.mapper.role.TabHaobanRoleMapper
;
import
com.gic.haoban.manage.service.dao.mapper.role.TabHaobanRoleMenuMapper
;
import
com.gic.haoban.manage.service.entity.TabHaobanWxEnterpriseRelated
;
import
com.gic.haoban.manage.service.entity.role.TabHaobanMenu
;
import
com.gic.haoban.manage.service.entity.role.TabHaobanRole
;
import
com.gic.haoban.manage.service.entity.role.TabHaobanRoleMenu
;
import
com.gic.haoban.manage.service.pojo.bo.role.HaobanMenuBO
;
import
com.gic.haoban.manage.service.service.MemberQueryService
;
import
com.gic.haoban.manage.service.service.role.HaobanMenuService
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.Logger
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.Collections
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.*
;
/**
* @author mozhu
...
...
@@ -21,9 +33,18 @@ import java.util.List;
*/
@Service
public
class
HaobanMenuServiceImpl
implements
HaobanMenuService
{
private
static
final
Logger
logger
=
LogManager
.
getLogger
(
HaobanMenuService
.
class
);
@Autowired
private
TabHaobanMenuMapper
tabHaobanMenuMapper
;
@Autowired
private
WxEnterpriseRelatedMapper
wxEnterpriseRelatedMapper
;
@Autowired
private
TabHaobanRoleMapper
roleMapper
;
@Autowired
private
TabHaobanRoleMenuMapper
roleMenuMapper
;
@Autowired
private
MenuApiService
menuApiService
;
@Override
public
TabHaobanMenu
queryById
(
String
menuCode
)
{
...
...
@@ -163,4 +184,76 @@ public class HaobanMenuServiceImpl implements HaobanMenuService {
public
void
deleteByMenuCode
(
String
menuCode
)
{
this
.
tabHaobanMenuMapper
.
deleteByMenuCode
(
menuCode
);
}
@Override
public
void
saveMenuFromGicEvent
(
String
params
)
{
logger
.
info
(
"服务开通-好办小程序={}"
,
params
);
JSONObject
json
=
JSONObject
.
parseObject
(
params
)
;
String
serviceCode
=
json
.
getString
(
"serviceCode"
)
;
String
enterpriseId
=
json
.
getString
(
"enterpriseId"
)
;
String
operationType
=
json
.
getString
(
"operationType"
)
;
Boolean
addOrDel
=
null
;
// 进行授权 auth 取消授权 cancel
if
(
"auth"
.
equals
(
operationType
))
{
addOrDel
=
true
;
}
if
(
"cancel"
.
equals
(
operationType
))
{
addOrDel
=
false
;
}
MenuListQDTO
qdto
=
new
MenuListQDTO
()
;
ServiceResponse
<
List
<
MenuDTO
>>
resp
=
this
.
menuApiService
.
listMenu
(
qdto
)
;
if
(!
resp
.
isSuccess
())
{
logger
.
info
(
"失败={}"
,
JSONObject
.
toJSONString
(
resp
));
return
;
}
List
<
TabHaobanWxEnterpriseRelated
>
wxEnterpriseList
=
this
.
wxEnterpriseRelatedMapper
.
listByEnterpriseId
(
enterpriseId
)
;
if
(
CollectionUtils
.
isEmpty
(
wxEnterpriseList
))
{
logger
.
info
(
"未关联企微={}"
,
enterpriseId
);
return
;
}
logger
.
info
(
"gic关联的企微={}"
,
JSONObject
.
toJSONString
(
wxEnterpriseList
));
List
<
MenuDTO
>
menuDTOList
=
resp
.
getResult
()
;
if
(
CollectionUtils
.
isEmpty
(
menuDTOList
))
{
logger
.
info
(
"无相关菜单"
);
return
;
}
for
(
MenuDTO
gicMenu
:
menuDTOList
)
{
List
<
String
>
menuCodeList
=
Arrays
.
asList
(
gicMenu
.
getMenuCode
())
;
List
<
Integer
>
addRoleTypeList
=
Arrays
.
asList
(
0
,
1
,
2
);
Date
now
=
new
Date
()
;
for
(
int
i
=
0
;
i
<
wxEnterpriseList
.
size
();
i
++)
{
TabHaobanWxEnterpriseRelated
item
=
wxEnterpriseList
.
get
(
i
)
;
String
wxEnterpriseId
=
item
.
getWxEnterpriseId
()
;
List
<
TabHaobanRoleMenu
>
insertMenuList
=
new
ArrayList
<>()
;
List
<
TabHaobanRole
>
list
=
this
.
roleMapper
.
getListByWxEnterpriseId
(
wxEnterpriseId
,
null
)
;
TabHaobanRoleMenu
menu
=
null
;
for
(
TabHaobanRole
role
:
list
)
{
int
roleType
=
role
.
getClerkType
()
;
if
(!
addRoleTypeList
.
contains
(
roleType
))
{
continue
;
}
Long
roleId
=
role
.
getRoleId
()
;
for
(
String
menuCode
:
menuCodeList
)
{
// 判断是否已存在
List
<
String
>
oldList
=
this
.
roleMenuMapper
.
getMenuInMenuCodes
(
wxEnterpriseId
,
roleId
,
Arrays
.
asList
(
menuCode
))
;
if
(
CollectionUtils
.
isNotEmpty
(
oldList
))
{
continue
;
}
menu
=
new
TabHaobanRoleMenu
()
;
menu
.
setRoleMenuId
(
UniqueIdUtils
.
uniqueLong
());
menu
.
setRoleId
(
roleId
);
menu
.
setUpdateTime
(
now
);
menu
.
setCreateTime
(
now
);
menu
.
setStatusFlag
(
1
);
menu
.
setWxEnterpriseId
(
wxEnterpriseId
);
menu
.
setMenuCode
(
menuCode
);
insertMenuList
.
add
(
menu
)
;
}
}
if
(
CollectionUtils
.
isNotEmpty
(
insertMenuList
))
{
this
.
roleMenuMapper
.
insertBatch
(
insertMenuList
);
}
}
}
}
}
haoban-manage3-service/src/main/resources/dubbo-haoban-manage-service.xml
View file @
52c46592
...
...
@@ -235,5 +235,6 @@
<dubbo:reference
id=
"contentProducerApiService"
interface=
"com.gic.content.api.service.ContentProducerApiService"
timeout=
"10000"
retries=
"0"
check=
"false"
/>
<dubbo:reference
interface=
"com.gic.content.api.service.ContentMaterialApiService"
id=
"contentMaterialApiService"
timeout=
"10000"
retries=
"0"
check=
"false"
/>
<dubbo:reference
interface=
"com.gic.content.api.service.ContentSettingApiService"
id=
"contentSettingApiService"
timeout=
"10000"
retries=
"0"
check=
"false"
/>
<dubbo:reference
interface=
"com.gic.clerk.api.service.MenuApiService"
id=
"menuApiService"
timeout=
"10000"
retries=
"0"
check=
"false"
/>
</beans>
\ No newline at end of file
haoban-manage3-service/src/main/resources/mapper/role/TabHaobanMenuMapper.xml
View file @
52c46592
...
...
@@ -17,17 +17,11 @@
<result
property=
"updateTime"
column=
"update_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"authControl"
column=
"auth_control"
/>
<result
property=
"btnCodeRel"
column=
"btn_code_rel"
/>
<result
column=
"app_code"
property=
"appCode"
/>
<result
column=
"fun_type"
property=
"funType"
/>
<result
column=
"no_open_flag"
property=
"noOpenFlag"
/>
<result
column=
"expire_flag"
property=
"expireFlag"
/>
<result
column=
"app_versions"
property=
"appVersions"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
menu_code , auth_control , btn_code_rel
, menu_name, menu_url, icon_url, menu_type, menu_sort, parent_code, status_flag,route_path,owner_ship, create_time, update_time
, app_code ,fun_type ,no_open_flag , expire_flag,app_versions
</sql>
<!--查询单个-->
...
...
@@ -41,11 +35,9 @@
<!--新增所有列-->
<insert
id=
"insert"
keyProperty=
"menuId"
useGeneratedKeys=
"true"
>
insert into tab_haoban_menu(menu_code, menu_name, menu_url, icon_url, menu_type, menu_sort, parent_code,
status_flag, route_path, owner_ship, create_time, update_time
, app_code ,fun_type ,no_open_flag , expire_flag,app_versions
)
status_flag, route_path, owner_ship, create_time, update_time)
values (#{menuCode}, #{menuName}, #{menuUrl}, #{iconUrl}, #{menuType}, #{menuSort}, #{parentCode},
#{statusFlag}, #{routePath}, #{ownerShip}, #{createTime}, #{updateTime}
, #{appCode} ,#{funType} ,#{noOpenFlag} , #{expireFlag},#{appVersions}
)
#{statusFlag}, #{routePath}, #{ownerShip}, #{createTime}, #{updateTime})
</insert>
<insert
id=
"insertBatch"
keyProperty=
"menuId"
useGeneratedKeys=
"true"
>
...
...
@@ -98,21 +90,6 @@
<if
test=
"updateTime != null"
>
update_time = #{updateTime},
</if>
<if
test=
"appCode != null"
>
app_code = #{appCode},
</if>
<if
test=
"funType != null"
>
fun_type = #{funType},
</if>
<if
test=
"noOpenFlag != null"
>
no_open_flag = #{noOpenFlag},
</if>
<if
test=
"expireFlag != null"
>
expire_flag = #{expireFlag},
</if>
<if
test=
"appVersions != null"
>
app_versions = #{appVersions},
</if>
</set>
where menu_code = #{menuCode}
</update>
...
...
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/controller/WxStaffController.java
View file @
52c46592
...
...
@@ -1450,7 +1450,7 @@ public class WxStaffController extends WebBaseController {
* @return
*/
@RequestMapping
(
value
=
"/queryMenuCodesByClerkType"
,
method
=
RequestMethod
.
GET
)
public
RestResponse
<
HaobanRoleDTO
>
queryMenuByClerkType
(
Integer
clerkType
,
String
staffId
,
String
wxEnterpriseId
)
{
public
RestResponse
<
HaobanRoleDTO
>
queryMenuByClerkType
(
Integer
clerkType
,
String
staffId
,
String
wxEnterpriseId
,
String
enterpriseId
)
{
if
(
clerkType
==
null
)
{
return
RestResponse
.
failure
(
Convert
.
toStr
(
HaoBanErrCode
.
ERR_2
.
getCode
()),
HaoBanErrCode
.
ERR_2
.
getMsg
());
}
...
...
@@ -1469,7 +1469,7 @@ public class WxStaffController extends WebBaseController {
return
RestResponse
.
successResult
(
serviceResponse
.
getResult
());
}
ServiceResponse
<
HaobanRoleDTO
>
serviceResponse
=
haobanRoleApiService
.
getMenuByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
1
);
.
getMenuByWxEnterpriseIdAndClerkType
(
wxEnterpriseId
,
clerkType
,
1
,
enterpriseId
);
return
RestResponse
.
successResult
(
serviceResponse
.
getResult
());
}
...
...
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