Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
cms
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
cms
Commits
04e6346d
提交
04e6346d
authored
7月 12, 2023
作者:
zhenjie
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'develop'
上级
341c907e
1fac1334
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
23 个修改的文件
包含
369 行增加
和
228 行删除
+369
-228
RoleInfoDTO.java
...rc/main/java/com/mmc/iuav/user/model/dto/RoleInfoDTO.java
+2
-0
CodeUtil.java
...mon-util/src/main/java/com/mmc/iuav/general/CodeUtil.java
+11
-5
MenuInfoController.java
...java/com/mmc/iuav/user/controller/MenuInfoController.java
+3
-17
RoleController.java
...ain/java/com/mmc/iuav/user/controller/RoleController.java
+13
-4
UserAccountController.java
...a/com/mmc/iuav/user/controller/UserAccountController.java
+22
-25
MenuInfoDao.java
...user/src/main/java/com/mmc/iuav/user/dao/MenuInfoDao.java
+1
-6
RoleDao.java
...ice-user/src/main/java/com/mmc/iuav/user/dao/RoleDao.java
+8
-3
UserServiceDao.java
...r/src/main/java/com/mmc/iuav/user/dao/UserServiceDao.java
+21
-1
MenuInfoDO.java
...er/src/main/java/com/mmc/iuav/user/entity/MenuInfoDO.java
+24
-1
RoleInfoDO.java
...er/src/main/java/com/mmc/iuav/user/entity/RoleInfoDO.java
+21
-1
UserRoleRel.java
...r/src/main/java/com/mmc/iuav/user/entity/UserRoleRel.java
+39
-0
MenuInfoService.java
.../main/java/com/mmc/iuav/user/service/MenuInfoService.java
+0
-5
RoleService.java
.../src/main/java/com/mmc/iuav/user/service/RoleService.java
+4
-1
UserAccountService.java
...in/java/com/mmc/iuav/user/service/UserAccountService.java
+23
-1
MenuInfoServiceImpl.java
...a/com/mmc/iuav/user/service/impl/MenuInfoServiceImpl.java
+0
-37
RoleServiceImpl.java
.../java/com/mmc/iuav/user/service/impl/RoleServiceImpl.java
+29
-7
UserAccountServiceImpl.java
...om/mmc/iuav/user/service/impl/UserAccountServiceImpl.java
+20
-17
MenuTreeUtil.java
...er/src/main/java/com/mmc/iuav/user/util/MenuTreeUtil.java
+4
-4
BackUserAccountDao.xml
...ice-user/src/main/resources/mapper/BackUserAccountDao.xml
+78
-29
MenuInfoDao.xml
...ms-service-user/src/main/resources/mapper/MenuInfoDao.xml
+0
-42
RoleDao.xml
...ce/cms-service-user/src/main/resources/mapper/RoleDao.xml
+45
-21
UserServiceDao.xml
...service-user/src/main/resources/mapper/UserServiceDao.xml
+0
-0
kustomization.yaml
kustomization/overlays/dev/kustomization.yaml
+1
-1
没有找到文件。
cms-common/cms-common-model/src/main/java/com/mmc/iuav/user/model/dto/RoleInfoDTO.java
浏览文件 @
04e6346d
...
@@ -29,5 +29,7 @@ public class RoleInfoDTO implements Serializable {
...
@@ -29,5 +29,7 @@ public class RoleInfoDTO implements Serializable {
private
String
remark
;
private
String
remark
;
@ApiModelProperty
(
value
=
"账号名称/创建人"
)
@ApiModelProperty
(
value
=
"账号名称/创建人"
)
private
String
userName
;
private
String
userName
;
@ApiModelProperty
(
value
=
"0不是超级管理员 1是超级管理员"
)
private
Integer
superAdmin
;
}
}
cms-common/cms-common-util/src/main/java/com/mmc/iuav/general/CodeUtil.java
浏览文件 @
04e6346d
...
@@ -30,10 +30,16 @@ public class CodeUtil {
...
@@ -30,10 +30,16 @@ public class CodeUtil {
return
"DELETE"
+
CodeUtil
.
getRandomNum
(
15
);
return
"DELETE"
+
CodeUtil
.
getRandomNum
(
15
);
}
}
public
static
String
createRoleNo
()
{
public
static
String
createRoleNo
(
String
roleNo
)
{
StringBuffer
sb
=
new
StringBuffer
();
return
getNewEquipmentNo
(
"A"
,
roleNo
);
sb
.
append
(
"A"
);
}
sb
.
append
(
CodeUtil
.
getRandomNum
(
4
));
return
sb
.
toString
();
public
static
String
getNewEquipmentNo
(
String
equipmentType
,
String
equipmentNo
)
{
String
newEquipmentNo
=
"A"
+
"0001"
;
if
(
equipmentNo
!=
null
&&
!
equipmentNo
.
isEmpty
())
{
int
newEquipment
=
Integer
.
parseInt
(
equipmentNo
.
substring
(
1
))
+
1
;
newEquipmentNo
=
String
.
format
(
equipmentType
+
"%04d"
,
newEquipment
);
}
return
newEquipmentNo
;
}
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/controller/MenuInfoController.java
浏览文件 @
04e6346d
...
@@ -2,16 +2,15 @@ package com.mmc.iuav.user.controller;
...
@@ -2,16 +2,15 @@ package com.mmc.iuav.user.controller;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.model.dto.MenuInfoDTO
;
import
com.mmc.iuav.user.model.dto.MenuInfoDTO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
import
com.mmc.iuav.user.service.MenuInfoService
;
import
com.mmc.iuav.user.service.MenuInfoService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiResponse
;
import
io.swagger.annotations.ApiResponse
;
import
io.swagger.annotations.ApiResponses
;
import
io.swagger.annotations.ApiResponses
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.
*
;
import
org.springframework.web.bind.annotation.
GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
javax.servlet.http.HttpServletRequest
;
import
org.springframework.web.bind.annotation.RestController
;
/**
/**
* @author: zj
* @author: zj
...
@@ -31,17 +30,4 @@ public class MenuInfoController extends BaseController {
...
@@ -31,17 +30,4 @@ public class MenuInfoController extends BaseController {
return
menuInfoService
.
listMenuInfo
();
return
menuInfoService
.
listMenuInfo
();
}
}
@ApiOperation
(
value
=
"根据角色id获取权限"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
MenuInfoDTO
.
class
)})
@GetMapping
(
"listRoleMenuInfo"
)
public
ResultBody
listRoleMenuInfo
(
@RequestParam
Integer
roleId
)
{
return
menuInfoService
.
listRoleMenuInfo
(
roleId
);
}
@ApiOperation
(
value
=
"修改角色菜单权限"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@PostMapping
(
"updateRoleMenuInfo"
)
public
ResultBody
updateRoleMenuInfo
(
HttpServletRequest
request
,
@RequestBody
RoleMenuInfoVO
roleMenuInfoVO
)
{
return
menuInfoService
.
updateRoleMenuInfo
(
roleMenuInfoVO
,
this
.
getUserLoginInfoFromRedis
(
request
));
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/controller/RoleController.java
浏览文件 @
04e6346d
...
@@ -4,9 +4,11 @@ import com.mmc.iuav.group.Create;
...
@@ -4,9 +4,11 @@ import com.mmc.iuav.group.Create;
import
com.mmc.iuav.group.Page
;
import
com.mmc.iuav.group.Page
;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.model.dto.MenuInfoDTO
;
import
com.mmc.iuav.user.model.dto.RoleInfoDTO
;
import
com.mmc.iuav.user.model.dto.RoleInfoDTO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
import
com.mmc.iuav.user.service.RoleService
;
import
com.mmc.iuav.user.service.RoleService
;
import
io.swagger.annotations.*
;
import
io.swagger.annotations.*
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -60,12 +62,19 @@ public class RoleController extends BaseController {
...
@@ -60,12 +62,19 @@ public class RoleController extends BaseController {
return
ResultBody
.
success
(
roleService
.
listPageRoleInfo
(
param
,
this
.
getUserLoginInfoFromRedis
(
request
)));
return
ResultBody
.
success
(
roleService
.
listPageRoleInfo
(
param
,
this
.
getUserLoginInfoFromRedis
(
request
)));
}
}
@ApiOperation
(
value
=
"根据角色id获取权限"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
MenuInfoDTO
.
class
)})
@GetMapping
(
"listRoleMenuInfo"
)
public
ResultBody
listRoleMenuInfo
(
@RequestParam
Integer
roleId
)
{
return
roleService
.
listRoleMenuInfo
(
roleId
);
}
@ApiOperation
(
value
=
"角色管理-当前角色绑定了那些账号"
)
@ApiOperation
(
value
=
"修改角色菜单权限"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@
GetMapping
(
"roleAccountList
"
)
@
PostMapping
(
"updateRoleMenuInfo
"
)
public
ResultBody
<
RoleInfoDTO
>
roleAccountList
(
@ApiParam
(
value
=
"角色id"
,
required
=
true
)
@RequestParam
Integer
id
)
{
public
ResultBody
updateRoleMenuInfo
(
HttpServletRequest
request
,
@RequestBody
RoleMenuInfoVO
roleMenuInfoVO
)
{
return
roleService
.
roleAccountList
(
id
);
return
roleService
.
updateRoleMenuInfo
(
roleMenuInfoVO
,
this
.
getUserLoginInfoFromRedis
(
request
)
);
}
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/controller/UserAccountController.java
浏览文件 @
04e6346d
...
@@ -4,7 +4,6 @@ import com.mmc.iuav.group.Page;
...
@@ -4,7 +4,6 @@ import com.mmc.iuav.group.Page;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.qo.BUserAccountQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.vo.UserAccountVO
;
import
com.mmc.iuav.user.model.vo.UserAccountVO
;
import
com.mmc.iuav.user.service.UserAccountService
;
import
com.mmc.iuav.user.service.UserAccountService
;
...
@@ -23,86 +22,86 @@ import java.util.List;
...
@@ -23,86 +22,86 @@ import java.util.List;
@Api
(
tags
=
"小程序用户账号相关接口"
)
@Api
(
tags
=
"小程序用户账号相关接口"
)
@RequestMapping
(
"/user-account/"
)
@RequestMapping
(
"/user-account/"
)
@RestController
@RestController
public
class
UserAccountController
extends
BaseController
{
public
class
UserAccountController
extends
BaseController
{
@Autowired
@Autowired
private
UserAccountService
userAccountService
;
private
UserAccountService
userAccountService
;
@ApiOperation
(
value
=
"客户列表"
)
@ApiOperation
(
value
=
"客户列表"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountVO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountVO
.
class
)
})
@PostMapping
(
"listAppUser"
)
@PostMapping
(
"listAppUser"
)
public
ResultBody
<
UserAccountVO
>
listAppUser
(
@Validated
(
value
=
{
Page
.
class
})
@RequestBody
UserAccountQO
userAccountQO
)
{
public
ResultBody
<
UserAccountVO
>
listAppUser
(
@Validated
(
value
=
{
Page
.
class
})
@RequestBody
UserAccountQO
userAccountQO
)
{
return
userAccountService
.
listAppUser
(
userAccountQO
);
return
userAccountService
.
listAppUser
(
userAccountQO
);
}
}
@ApiOperation
(
value
=
"获取用户信息"
)
@ApiOperation
(
value
=
"获取用户信息"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountVO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountVO
.
class
)
})
@GetMapping
(
"info"
)
@GetMapping
(
"info"
)
public
ResultBody
info
(
HttpServletRequest
request
)
{
public
ResultBody
info
(
HttpServletRequest
request
)
{
return
ResultBody
.
success
(
userAccountService
.
getUserAccountById
(
this
.
getUserLoginInfoFromRedis
(
request
).
getUserAccountId
()));
return
ResultBody
.
success
(
userAccountService
.
getUserAccountById
(
this
.
getUserLoginInfoFromRedis
(
request
).
getUserAccountId
()));
}
}
@ApiOperation
(
value
=
"修改用户信息"
)
@ApiOperation
(
value
=
"修改用户信息"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)
})
@PostMapping
(
"update"
)
@PostMapping
(
"update"
)
public
ResultBody
update
(
@Validated
(
value
=
{
Update
.
class
})
@RequestBody
UserAccountVO
userAccountVO
)
{
public
ResultBody
update
(
@Validated
(
value
=
{
Update
.
class
})
@RequestBody
UserAccountVO
userAccountVO
)
{
return
userAccountService
.
update
(
userAccountVO
);
return
userAccountService
.
update
(
userAccountVO
);
}
}
@ApiOperation
(
value
=
"获取用户基本信息"
,
hidden
=
true
)
@ApiOperation
(
value
=
"获取用户基本信息"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@GetMapping
(
"feignGetUserSimpleInfo"
)
@GetMapping
(
"feignGetUserSimpleInfo"
)
public
UserAccountSimpleDTO
feignGetUserSimpleInfo
(
@RequestParam
Integer
userAccountId
){
public
UserAccountSimpleDTO
feignGetUserSimpleInfo
(
@RequestParam
Integer
userAccountId
)
{
return
userAccountService
.
getUserSimpleInfo
(
userAccountId
);
return
userAccountService
.
getUserSimpleInfo
(
userAccountId
);
}
}
@ApiOperation
(
value
=
"根据用户地区查询后台用户id"
,
hidden
=
true
)
@ApiOperation
(
value
=
"根据用户地区查询后台用户id"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@GetMapping
(
"feignListUserAccountIds"
)
@GetMapping
(
"feignListUserAccountIds"
)
public
List
<
Integer
>
feignListUserAccountIds
(
@RequestParam
Integer
provinceCode
,
@RequestParam
(
required
=
false
)
Integer
cityCode
,
@RequestParam
(
required
=
false
)
Integer
districtCode
)
{
public
List
<
Integer
>
feignListUserAccountIds
(
@RequestParam
Integer
provinceCode
,
@RequestParam
(
required
=
false
)
Integer
cityCode
,
@RequestParam
(
required
=
false
)
Integer
districtCode
)
{
return
userAccountService
.
feignListUserAccountIds
(
provinceCode
,
cityCode
,
districtCode
);
return
userAccountService
.
feignListUserAccountIds
(
provinceCode
,
cityCode
,
districtCode
);
}
}
@ApiOperation
(
value
=
"授权手机号"
)
@ApiOperation
(
value
=
"授权手机号"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
Integer
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
Integer
.
class
)
})
@GetMapping
(
"getUserPhoneNumber"
)
@GetMapping
(
"getUserPhoneNumber"
)
public
ResultBody
getUserPhoneNumber
(
HttpServletRequest
request
,
public
ResultBody
getUserPhoneNumber
(
HttpServletRequest
request
,
@ApiParam
(
value
=
"授权手机号code"
,
required
=
true
)
@RequestParam
String
code
)
{
@ApiParam
(
value
=
"授权手机号code"
,
required
=
true
)
@RequestParam
String
code
)
{
return
userAccountService
.
getUserPhoneNumber
(
this
.
getUserLoginInfoFromRedis
(
request
).
getUserAccountId
(),
code
);
return
userAccountService
.
getUserPhoneNumber
(
this
.
getUserLoginInfoFromRedis
(
request
).
getUserAccountId
(),
code
);
}
}
@ApiOperation
(
value
=
"根据用户id查询用户信息"
,
hidden
=
true
)
@ApiOperation
(
value
=
"根据用户id查询用户信息"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@PostMapping
(
"feignListUserAccountByIds"
)
@PostMapping
(
"feignListUserAccountByIds"
)
public
List
<
UserAccountSimpleDTO
>
feignListUserAccountByIds
(
@RequestBody
List
<
Integer
>
ids
){
public
List
<
UserAccountSimpleDTO
>
feignListUserAccountByIds
(
@RequestBody
List
<
Integer
>
ids
)
{
return
userAccountService
.
feignListUserAccountByIds
(
ids
);
return
userAccountService
.
feignListUserAccountByIds
(
ids
);
}
}
@ApiOperation
(
value
=
"根据条件查询用户信息"
,
hidden
=
true
)
@ApiOperation
(
value
=
"根据条件查询用户信息"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@PostMapping
(
"feignListAppUserAccount"
)
@PostMapping
(
"feignListAppUserAccount"
)
public
List
<
UserAccountSimpleDTO
>
feignListAppUserAccount
(
@ApiParam
(
value
=
"账号查询QO"
,
required
=
true
)
@RequestBody
UserAccountQO
userAccountQO
)
{
public
List
<
UserAccountSimpleDTO
>
feignListAppUserAccount
(
@ApiParam
(
value
=
"账号查询QO"
,
required
=
true
)
@RequestBody
UserAccountQO
userAccountQO
)
{
return
userAccountService
.
feignListUserAccount
(
userAccountQO
);
return
userAccountService
.
feignListUserAccount
(
userAccountQO
);
}
}
@ApiOperation
(
value
=
"根据用户ids上级推荐人信息"
,
hidden
=
true
)
@ApiOperation
(
value
=
"根据用户ids上级推荐人信息"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@PostMapping
(
"feignListRcdUserInfo"
)
@PostMapping
(
"feignListRcdUserInfo"
)
public
List
<
UserAccountSimpleDTO
>
feignListRcdUserInfo
(
@RequestBody
List
<
Integer
>
userIds
){
public
List
<
UserAccountSimpleDTO
>
feignListRcdUserInfo
(
@RequestBody
List
<
Integer
>
userIds
)
{
return
userAccountService
.
feignListRcdUserInfo
(
userIds
);
return
userAccountService
.
feignListRcdUserInfo
(
userIds
);
}
}
@ApiOperation
(
value
=
"查询上级推荐人id"
,
hidden
=
true
)
@ApiOperation
(
value
=
"查询上级推荐人id"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
Integer
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
Integer
.
class
)
})
@GetMapping
(
"feignGetSuperiorRef"
)
@GetMapping
(
"feignGetSuperiorRef"
)
public
Integer
feignGetSuperiorRef
(
@RequestParam
Integer
userAccountId
){
public
Integer
feignGetSuperiorRef
(
@RequestParam
Integer
userAccountId
)
{
return
userAccountService
.
feignGetSuperiorRef
(
userAccountId
);
return
userAccountService
.
feignGetSuperiorRef
(
userAccountId
);
}
}
@ApiOperation
(
value
=
"查询上级推荐人信息"
,
hidden
=
true
)
@ApiOperation
(
value
=
"查询上级推荐人信息"
,
hidden
=
true
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
UserAccountSimpleDTO
.
class
)
})
@GetMapping
(
"feignGetUserRcdInfo"
)
@GetMapping
(
"feignGetUserRcdInfo"
)
public
UserAccountSimpleDTO
feignGetUserRcdInfo
(
@RequestParam
Integer
userAccountId
){
public
UserAccountSimpleDTO
feignGetUserRcdInfo
(
@RequestParam
Integer
userAccountId
)
{
return
userAccountService
.
feignGetUserRcdInfo
(
userAccountId
);
return
userAccountService
.
feignGetUserRcdInfo
(
userAccountId
);
}
}
...
@@ -113,6 +112,4 @@ public class UserAccountController extends BaseController{
...
@@ -113,6 +112,4 @@ public class UserAccountController extends BaseController{
return
userAccountService
.
removeAppAccount
(
userAccountId
);
return
userAccountService
.
removeAppAccount
(
userAccountId
);
}
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/dao/MenuInfoDao.java
浏览文件 @
04e6346d
...
@@ -2,7 +2,6 @@ package com.mmc.iuav.user.dao;
...
@@ -2,7 +2,6 @@ package com.mmc.iuav.user.dao;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.List
;
...
@@ -12,11 +11,7 @@ import java.util.List;
...
@@ -12,11 +11,7 @@ import java.util.List;
*/
*/
@Mapper
@Mapper
public
interface
MenuInfoDao
{
public
interface
MenuInfoDao
{
List
<
MenuInfoDO
>
listMenuInfo
();
List
<
MenuInfoDO
>
listRoleMenuInfo
(
Integer
roleId
);
void
batchAddMenuIds
(
Integer
roleId
,
@Param
(
"addMenuIds"
)
List
<
Integer
>
addMenuIds
);
List
<
MenuInfoDO
>
listMenuInfo
(
);
void
batchDeleteMenuIds
(
Integer
roleId
,
@Param
(
"deleteMenuIds"
)
List
<
Integer
>
deleteMenuIds
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/dao/RoleDao.java
浏览文件 @
04e6346d
package
com
.
mmc
.
iuav
.
user
.
dao
;
package
com
.
mmc
.
iuav
.
user
.
dao
;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
com.mmc.iuav.user.entity.RoleInfoDO
;
import
com.mmc.iuav.user.entity.RoleInfoDO
;
import
com.mmc.iuav.user.entity.UserAccountDO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
...
@@ -35,7 +35,12 @@ public interface RoleDao {
...
@@ -35,7 +35,12 @@ public interface RoleDao {
Integer
countNotDelUserAccountByRole
(
Integer
id
);
Integer
countNotDelUserAccountByRole
(
Integer
id
);
List
<
UserAccountDO
>
roleAccountList
(
Integer
id
);
String
findList
();
List
<
MenuInfoDO
>
listRoleMenuInfo
(
Integer
roleId
);
void
batchAddMenuIds
(
Integer
roleId
,
List
<
Integer
>
addMenuIds
);
void
batchDeleteMenuIds
(
Integer
roleId
,
List
<
Integer
>
deleteMenuIds
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/dao/UserServiceDao.java
浏览文件 @
04e6346d
...
@@ -17,6 +17,7 @@ import java.util.List;
...
@@ -17,6 +17,7 @@ import java.util.List;
public
interface
UserServiceDao
{
public
interface
UserServiceDao
{
/**
/**
* 根据用户unionId查询用户信息
* 根据用户unionId查询用户信息
*
* @param unionId
* @param unionId
* @return
* @return
*/
*/
...
@@ -24,12 +25,14 @@ public interface UserServiceDao {
...
@@ -24,12 +25,14 @@ public interface UserServiceDao {
/**
/**
* 插入用户信息
* 插入用户信息
*
* @param userAccountDO
* @param userAccountDO
*/
*/
void
insertUserAccount
(
UserAccountDO
userAccountDO
);
void
insertUserAccount
(
UserAccountDO
userAccountDO
);
/**
/**
* 根据用户id查询用户信息
* 根据用户id查询用户信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -37,12 +40,14 @@ public interface UserServiceDao {
...
@@ -37,12 +40,14 @@ public interface UserServiceDao {
/**
/**
* 修改用户信息
* 修改用户信息
*
* @param userAccountDO
* @param userAccountDO
*/
*/
void
update
(
UserAccountDO
userAccountDO
);
void
update
(
UserAccountDO
userAccountDO
);
/**
/**
* 根据用户地区查询后台用户id
* 根据用户地区查询后台用户id
*
* @param provinceCode
* @param provinceCode
* @param cityCode
* @param cityCode
* @param districtCode
* @param districtCode
...
@@ -52,6 +57,7 @@ public interface UserServiceDao {
...
@@ -52,6 +57,7 @@ public interface UserServiceDao {
/**
/**
* 登录账号密码查询用户信息
* 登录账号密码查询用户信息
*
* @param accountNo
* @param accountNo
* @param passWord
* @param passWord
* @return
* @return
...
@@ -60,6 +66,7 @@ public interface UserServiceDao {
...
@@ -60,6 +66,7 @@ public interface UserServiceDao {
/**
/**
* 批量获取用户信息
* 批量获取用户信息
*
* @param userAccountQO
* @param userAccountQO
* @return
* @return
*/
*/
...
@@ -67,6 +74,7 @@ public interface UserServiceDao {
...
@@ -67,6 +74,7 @@ public interface UserServiceDao {
/**
/**
* 删除用户
* 删除用户
*
* @param removeNO
* @param removeNO
* @param userAccountId
* @param userAccountId
*/
*/
...
@@ -74,6 +82,7 @@ public interface UserServiceDao {
...
@@ -74,6 +82,7 @@ public interface UserServiceDao {
/**
/**
* 根据账号名称查询数量
* 根据账号名称查询数量
*
* @param excludeId
* @param excludeId
* @param accountNo
* @param accountNo
* @return
* @return
...
@@ -82,6 +91,7 @@ public interface UserServiceDao {
...
@@ -82,6 +91,7 @@ public interface UserServiceDao {
/**
/**
* 查询用户数量
* 查询用户数量
*
* @param param
* @param param
* @return
* @return
*/
*/
...
@@ -89,6 +99,7 @@ public interface UserServiceDao {
...
@@ -89,6 +99,7 @@ public interface UserServiceDao {
/**
/**
* 查询用户信息
* 查询用户信息
*
* @param param
* @param param
* @return
* @return
*/
*/
...
@@ -96,6 +107,7 @@ public interface UserServiceDao {
...
@@ -96,6 +107,7 @@ public interface UserServiceDao {
/**
/**
* 修改用户密码
* 修改用户密码
*
* @param id
* @param id
* @param passWord
* @param passWord
*/
*/
...
@@ -103,6 +115,7 @@ public interface UserServiceDao {
...
@@ -103,6 +115,7 @@ public interface UserServiceDao {
/**
/**
* 获取用户密码
* 获取用户密码
*
* @param id
* @param id
* @return
* @return
*/
*/
...
@@ -110,13 +123,15 @@ public interface UserServiceDao {
...
@@ -110,13 +123,15 @@ public interface UserServiceDao {
/**
/**
* 根据id查询用户信息
* 根据id查询用户信息
*
* @param userIds
* @param userIds
* @return
* @return
*/
*/
List
<
UserAccountDO
>
listUserAccountByIds
(
@Param
(
"userIds"
)
List
<
Integer
>
userIds
);
List
<
UserAccountDO
>
listUserAccountByIds
(
@Param
(
"userIds"
)
List
<
Integer
>
userIds
);
/**
/**
* 获取用户推荐人信息
* 获取用户推荐人信息
*
* @param userIds
* @param userIds
* @return
* @return
*/
*/
...
@@ -124,6 +139,7 @@ public interface UserServiceDao {
...
@@ -124,6 +139,7 @@ public interface UserServiceDao {
/**
/**
* 获取推荐人信息
* 获取推荐人信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -131,6 +147,7 @@ public interface UserServiceDao {
...
@@ -131,6 +147,7 @@ public interface UserServiceDao {
/**
/**
* 获取用户推荐信息
* 获取用户推荐信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -138,6 +155,7 @@ public interface UserServiceDao {
...
@@ -138,6 +155,7 @@ public interface UserServiceDao {
/**
/**
* 用户数量
* 用户数量
*
* @param param
* @param param
* @return
* @return
*/
*/
...
@@ -145,8 +163,10 @@ public interface UserServiceDao {
...
@@ -145,8 +163,10 @@ public interface UserServiceDao {
/**
/**
* 用户信息
* 用户信息
*
* @param param
* @param param
* @return
* @return
*/
*/
List
<
UserAccountDO
>
listAppUser
(
UserAccountQO
param
);
List
<
UserAccountDO
>
listAppUser
(
UserAccountQO
param
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/entity/MenuInfoDO.java
浏览文件 @
04e6346d
...
@@ -18,14 +18,37 @@ import java.util.Date;
...
@@ -18,14 +18,37 @@ import java.util.Date;
public
class
MenuInfoDO
implements
Serializable
{
public
class
MenuInfoDO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
4992870152816350664L
;
private
static
final
long
serialVersionUID
=
-
4992870152816350664L
;
private
Integer
id
;
private
Integer
id
;
/**
* 父级id
*/
private
Integer
pid
;
private
Integer
pid
;
/**
* 菜单名
*/
private
String
menuName
;
private
String
menuName
;
private
String
portType
;
/**
* 菜单类型:0菜单,1按钮
*/
private
String
domType
;
private
String
domType
;
/**
* 菜单路径
*/
private
String
pathInfo
;
private
String
pathInfo
;
/**
* 菜单图标
*/
private
String
icon
;
private
String
icon
;
/**
* 序号
*/
private
Integer
sort
;
private
Integer
sort
;
/**
* 创建时间
*/
private
Date
createTime
;
private
Date
createTime
;
/**
* 更新时间
*/
private
Date
updateTime
;
private
Date
updateTime
;
public
MenuInfoDTO
buildMenuInfoDTO
()
{
public
MenuInfoDTO
buildMenuInfoDTO
()
{
...
...
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/entity/RoleInfoDO.java
浏览文件 @
04e6346d
package
com
.
mmc
.
iuav
.
user
.
entity
;
package
com
.
mmc
.
iuav
.
user
.
entity
;
import
com.alibaba.fastjson2.annotation.JSONField
;
import
com.mmc.iuav.user.model.dto.RoleInfoDTO
;
import
com.mmc.iuav.user.model.dto.RoleInfoDTO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
lombok.AllArgsConstructor
;
import
lombok.AllArgsConstructor
;
...
@@ -8,6 +9,7 @@ import lombok.Data;
...
@@ -8,6 +9,7 @@ import lombok.Data;
import
lombok.NoArgsConstructor
;
import
lombok.NoArgsConstructor
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.List
;
/**
/**
* @Author small
* @Author small
...
@@ -41,13 +43,15 @@ public class RoleInfoDO {
...
@@ -41,13 +43,15 @@ public class RoleInfoDO {
/**
/**
* 创建时间
* 创建时间
*/
*/
@JSONField
(
format
=
"yyyy-MM-dd HH:mm:ss"
)
private
Date
createTime
;
private
Date
createTime
;
/**
/**
* 更新时间
* 更新时间
*/
*/
@JSONField
(
format
=
"yyyy-MM-dd HH:mm:ss"
)
private
Date
updateTime
;
private
Date
updateTime
;
/**
/**
* 账号id
*
创建角色
账号id
*/
*/
private
Integer
userAccountId
;
private
Integer
userAccountId
;
/**
/**
...
@@ -55,6 +59,21 @@ public class RoleInfoDO {
...
@@ -55,6 +59,21 @@ public class RoleInfoDO {
*/
*/
private
String
userName
;
private
String
userName
;
/**
* 角色关联账号表
*/
List
<
UserRoleRel
>
userRoleRelList
;
/**
* 角色关联菜单
*/
List
<
MenuInfoDO
>
menuInfoDOList
;
/**
* 0不是超级管理员 1是超级管理员
*/
private
Integer
superAdmin
;
/**
/**
* DTO转换
* DTO转换
...
@@ -64,6 +83,7 @@ public class RoleInfoDO {
...
@@ -64,6 +83,7 @@ public class RoleInfoDO {
public
RoleInfoDTO
buildRoleInfoDTO
()
{
public
RoleInfoDTO
buildRoleInfoDTO
()
{
return
RoleInfoDTO
.
builder
().
id
(
this
.
id
).
roleNo
(
this
.
roleNo
).
roleName
(
this
.
roleName
)
return
RoleInfoDTO
.
builder
().
id
(
this
.
id
).
roleNo
(
this
.
roleNo
).
roleName
(
this
.
roleName
)
.
userName
(
this
.
userName
)
.
userName
(
this
.
userName
)
.
superAdmin
(
this
.
superAdmin
)
.
remark
(
this
.
remark
).
build
();
.
remark
(
this
.
remark
).
build
();
}
}
...
...
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/entity/UserRoleRel.java
0 → 100644
浏览文件 @
04e6346d
package
com
.
mmc
.
iuav
.
user
.
entity
;
import
com.alibaba.fastjson2.annotation.JSONField
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.util.Date
;
/**
* @Author small
* @Date 2023/7/12 13:29
* @Version 1.0
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public
class
UserRoleRel
{
/**
* 角色与账号关联表id
*/
private
Integer
id
;
/**
* 账号关联角色id
*/
private
Integer
userAccountId
;
/**
* 角色id
*/
private
Integer
roleId
;
/**
* 角色与账号关联表id
*/
@JSONField
(
format
=
"yyyy-MM-dd HH:mm:ss"
)
private
Date
createTime
;
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/MenuInfoService.java
浏览文件 @
04e6346d
package
com
.
mmc
.
iuav
.
user
.
service
;
package
com
.
mmc
.
iuav
.
user
.
service
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
/**
/**
* @author: zj
* @author: zj
* @Date: 2023/7/11 14:13
* @Date: 2023/7/11 14:13
*/
*/
public
interface
MenuInfoService
{
public
interface
MenuInfoService
{
ResultBody
updateRoleMenuInfo
(
RoleMenuInfoVO
roleMenuInfoVO
,
LoginSuccessDTO
userLoginInfoFromRedis
);
ResultBody
listMenuInfo
();
ResultBody
listMenuInfo
();
ResultBody
listRoleMenuInfo
(
Integer
roleId
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/RoleService.java
浏览文件 @
04e6346d
...
@@ -5,6 +5,7 @@ import com.mmc.iuav.response.ResultBody;
...
@@ -5,6 +5,7 @@ import com.mmc.iuav.response.ResultBody;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
/**
/**
...
@@ -21,5 +22,7 @@ public interface RoleService {
...
@@ -21,5 +22,7 @@ public interface RoleService {
PageResult
listPageRoleInfo
(
RoleInfoQO
param
,
LoginSuccessDTO
userLoginInfoFromRedis
);
PageResult
listPageRoleInfo
(
RoleInfoQO
param
,
LoginSuccessDTO
userLoginInfoFromRedis
);
ResultBody
roleAccountList
(
Integer
id
);
ResultBody
listRoleMenuInfo
(
Integer
roleId
);
ResultBody
updateRoleMenuInfo
(
RoleMenuInfoVO
roleMenuInfoVO
,
LoginSuccessDTO
userLoginInfoFromRedis
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/UserAccountService.java
浏览文件 @
04e6346d
...
@@ -4,7 +4,6 @@ import com.mmc.iuav.response.ResultBody;
...
@@ -4,7 +4,6 @@ import com.mmc.iuav.response.ResultBody;
import
com.mmc.iuav.user.entity.UserAccountDO
;
import
com.mmc.iuav.user.entity.UserAccountDO
;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.qo.BUserAccountQO
;
import
com.mmc.iuav.user.model.qo.BUserAccountQO
;
import
com.mmc.iuav.user.model.qo.LoginUserQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.vo.BUserAccountVO
;
import
com.mmc.iuav.user.model.vo.BUserAccountVO
;
import
com.mmc.iuav.user.model.vo.UserAccountVO
;
import
com.mmc.iuav.user.model.vo.UserAccountVO
;
...
@@ -18,6 +17,7 @@ import java.util.List;
...
@@ -18,6 +17,7 @@ import java.util.List;
public
interface
UserAccountService
{
public
interface
UserAccountService
{
/**
/**
* Get the user account
* Get the user account
*
* @param unionId
* @param unionId
* @return
* @return
*/
*/
...
@@ -25,12 +25,14 @@ public interface UserAccountService {
...
@@ -25,12 +25,14 @@ public interface UserAccountService {
/**
/**
* Insert the user account
* Insert the user account
*
* @param userAccountDO
* @param userAccountDO
*/
*/
void
insertUserAccount
(
UserAccountDO
userAccountDO
);
void
insertUserAccount
(
UserAccountDO
userAccountDO
);
/**
/**
* 通过用户id获取用户信息
* 通过用户id获取用户信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -38,6 +40,7 @@ public interface UserAccountService {
...
@@ -38,6 +40,7 @@ public interface UserAccountService {
/**
/**
* 修改用户信息
* 修改用户信息
*
* @param userAccountVO
* @param userAccountVO
* @return
* @return
*/
*/
...
@@ -45,6 +48,7 @@ public interface UserAccountService {
...
@@ -45,6 +48,7 @@ public interface UserAccountService {
/**
/**
* 获取用户基本信息
* 获取用户基本信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -52,6 +56,7 @@ public interface UserAccountService {
...
@@ -52,6 +56,7 @@ public interface UserAccountService {
/**
/**
* 根据用户地区查询后台用户id
* 根据用户地区查询后台用户id
*
* @param provinceCode
* @param provinceCode
* @param cityCode
* @param cityCode
* @param districtCode
* @param districtCode
...
@@ -61,6 +66,7 @@ public interface UserAccountService {
...
@@ -61,6 +66,7 @@ public interface UserAccountService {
/**
/**
* 添加后台用户
* 添加后台用户
*
* @param bUserAccountVO
* @param bUserAccountVO
* @return
* @return
*/
*/
...
@@ -68,6 +74,7 @@ public interface UserAccountService {
...
@@ -68,6 +74,7 @@ public interface UserAccountService {
/**
/**
* 删除用户信
* 删除用户信
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -75,6 +82,7 @@ public interface UserAccountService {
...
@@ -75,6 +82,7 @@ public interface UserAccountService {
/**
/**
* 后台用户列表
* 后台用户列表
*
* @param bUserAccountQO
* @param bUserAccountQO
* @return
* @return
*/
*/
...
@@ -82,6 +90,7 @@ public interface UserAccountService {
...
@@ -82,6 +90,7 @@ public interface UserAccountService {
/**
/**
* 登录账号密码查询用户信息
* 登录账号密码查询用户信息
*
* @param accountNo
* @param accountNo
* @param passWord
* @param passWord
* @return
* @return
...
@@ -90,6 +99,7 @@ public interface UserAccountService {
...
@@ -90,6 +99,7 @@ public interface UserAccountService {
/**
/**
* 内部获取用户列表
* 内部获取用户列表
*
* @param userAccountQO
* @param userAccountQO
* @return
* @return
*/
*/
...
@@ -97,6 +107,7 @@ public interface UserAccountService {
...
@@ -97,6 +107,7 @@ public interface UserAccountService {
/**
/**
* 修改用户信息
* 修改用户信息
*
* @param bUserAccountVO
* @param bUserAccountVO
* @return
* @return
*/
*/
...
@@ -104,6 +115,7 @@ public interface UserAccountService {
...
@@ -104,6 +115,7 @@ public interface UserAccountService {
/**
/**
* 修改用户密码
* 修改用户密码
*
* @param account
* @param account
* @return
* @return
*/
*/
...
@@ -111,6 +123,7 @@ public interface UserAccountService {
...
@@ -111,6 +123,7 @@ public interface UserAccountService {
/**
/**
* 验证用户密码
* 验证用户密码
*
* @param id
* @param id
* @param authPwd
* @param authPwd
* @return
* @return
...
@@ -119,6 +132,7 @@ public interface UserAccountService {
...
@@ -119,6 +132,7 @@ public interface UserAccountService {
/**
/**
* 授权手机号
* 授权手机号
*
* @param id
* @param id
* @param code
* @param code
* @return
* @return
...
@@ -127,6 +141,7 @@ public interface UserAccountService {
...
@@ -127,6 +141,7 @@ public interface UserAccountService {
/**
/**
* 根据id获取用户信息
* 根据id获取用户信息
*
* @param ids
* @param ids
* @return
* @return
*/
*/
...
@@ -134,6 +149,7 @@ public interface UserAccountService {
...
@@ -134,6 +149,7 @@ public interface UserAccountService {
/**
/**
* 根据用户id获取推荐人信息
* 根据用户id获取推荐人信息
*
* @param userIds
* @param userIds
* @return
* @return
*/
*/
...
@@ -141,6 +157,7 @@ public interface UserAccountService {
...
@@ -141,6 +157,7 @@ public interface UserAccountService {
/**
/**
* 获取推荐人id
* 获取推荐人id
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -148,6 +165,7 @@ public interface UserAccountService {
...
@@ -148,6 +165,7 @@ public interface UserAccountService {
/**
/**
* 获取推荐人信息
* 获取推荐人信息
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
...
@@ -155,6 +173,7 @@ public interface UserAccountService {
...
@@ -155,6 +173,7 @@ public interface UserAccountService {
/**
/**
* 用户列表
* 用户列表
*
* @param userAccountQO
* @param userAccountQO
* @return
* @return
*/
*/
...
@@ -162,8 +181,11 @@ public interface UserAccountService {
...
@@ -162,8 +181,11 @@ public interface UserAccountService {
/**
/**
* 删除小程序用户
* 删除小程序用户
*
* @param userAccountId
* @param userAccountId
* @return
* @return
*/
*/
ResultBody
removeAppAccount
(
Integer
userAccountId
);
ResultBody
removeAppAccount
(
Integer
userAccountId
);
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/impl/MenuInfoServiceImpl.java
浏览文件 @
04e6346d
...
@@ -2,18 +2,12 @@ package com.mmc.iuav.user.service.impl;
...
@@ -2,18 +2,12 @@ package com.mmc.iuav.user.service.impl;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.dao.MenuInfoDao
;
import
com.mmc.iuav.user.dao.MenuInfoDao
;
import
com.mmc.iuav.user.dao.RoleDao
;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
com.mmc.iuav.user.entity.RoleInfoDO
;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.dto.MenuInfoDTO
;
import
com.mmc.iuav.user.model.dto.MenuInfoDTO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
import
com.mmc.iuav.user.service.MenuInfoService
;
import
com.mmc.iuav.user.service.MenuInfoService
;
import
com.mmc.iuav.user.util.MenuTreeUtil
;
import
com.mmc.iuav.user.util.MenuTreeUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -27,31 +21,6 @@ public class MenuInfoServiceImpl implements MenuInfoService {
...
@@ -27,31 +21,6 @@ public class MenuInfoServiceImpl implements MenuInfoService {
@Autowired
@Autowired
private
MenuInfoDao
menuInfoDao
;
private
MenuInfoDao
menuInfoDao
;
@Autowired
private
RoleDao
roleDao
;
@Transactional
@Override
public
ResultBody
updateRoleMenuInfo
(
RoleMenuInfoVO
roleMenuInfoVO
,
LoginSuccessDTO
loginSuccessDTO
)
{
// 判断该角色的菜单是否可以修改
RoleInfoDO
roleInfo
=
roleDao
.
getRoleInfo
(
roleMenuInfoVO
.
getRoleId
());
if
(!
CollectionUtils
.
isEmpty
(
roleMenuInfoVO
.
getMenuInfoIds
()))
{
List
<
MenuInfoDO
>
menuInfoDOList
=
menuInfoDao
.
listRoleMenuInfo
(
roleMenuInfoVO
.
getRoleId
());
List
<
Integer
>
existMenuIds
=
menuInfoDOList
.
stream
().
map
(
MenuInfoDO:
:
getId
).
collect
(
Collectors
.
toList
());
// 新添加的权限
List
<
Integer
>
addMenuIds
=
roleMenuInfoVO
.
getMenuInfoIds
().
stream
().
filter
(
v
->
!
existMenuIds
.
contains
(
v
)).
collect
(
Collectors
.
toList
());
// 需删除的权限
List
<
Integer
>
deleteMenuIds
=
existMenuIds
.
stream
().
filter
(
v
->
!
roleMenuInfoVO
.
getMenuInfoIds
().
contains
(
v
)).
collect
(
Collectors
.
toList
());
if
(!
CollectionUtils
.
isEmpty
(
addMenuIds
))
{
menuInfoDao
.
batchAddMenuIds
(
roleMenuInfoVO
.
getRoleId
(),
addMenuIds
);
}
if
(!
CollectionUtils
.
isEmpty
(
deleteMenuIds
))
{
menuInfoDao
.
batchDeleteMenuIds
(
roleMenuInfoVO
.
getRoleId
(),
deleteMenuIds
);
}
}
return
ResultBody
.
success
();
}
@Override
@Override
public
ResultBody
listMenuInfo
()
{
public
ResultBody
listMenuInfo
()
{
List
<
MenuInfoDO
>
menuInfoDOList
=
menuInfoDao
.
listMenuInfo
();
List
<
MenuInfoDO
>
menuInfoDOList
=
menuInfoDao
.
listMenuInfo
();
...
@@ -59,10 +28,4 @@ public class MenuInfoServiceImpl implements MenuInfoService {
...
@@ -59,10 +28,4 @@ public class MenuInfoServiceImpl implements MenuInfoService {
return
ResultBody
.
success
(
MenuTreeUtil
.
buildTreePCMenu
(
menuInfoDTOS
));
return
ResultBody
.
success
(
MenuTreeUtil
.
buildTreePCMenu
(
menuInfoDTOS
));
}
}
@Override
public
ResultBody
listRoleMenuInfo
(
Integer
roleId
)
{
List
<
MenuInfoDO
>
menuInfoDOList
=
menuInfoDao
.
listRoleMenuInfo
(
roleId
);
List
<
MenuInfoDTO
>
menuInfoDTOS
=
menuInfoDOList
.
stream
().
map
(
MenuInfoDO:
:
buildMenuInfoDTO
).
collect
(
Collectors
.
toList
());
return
ResultBody
.
success
(
MenuTreeUtil
.
buildTreePCMenu
(
menuInfoDTOS
));
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/impl/RoleServiceImpl.java
浏览文件 @
04e6346d
...
@@ -5,15 +5,18 @@ import com.mmc.iuav.page.PageResult;
...
@@ -5,15 +5,18 @@ import com.mmc.iuav.page.PageResult;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultEnum
;
import
com.mmc.iuav.response.ResultEnum
;
import
com.mmc.iuav.user.dao.RoleDao
;
import
com.mmc.iuav.user.dao.RoleDao
;
import
com.mmc.iuav.user.entity.MenuInfoDO
;
import
com.mmc.iuav.user.entity.RoleInfoDO
;
import
com.mmc.iuav.user.entity.RoleInfoDO
;
import
com.mmc.iuav.user.entity.UserAccountDO
;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.dto.LoginSuccessDTO
;
import
com.mmc.iuav.user.model.dto.
UserAccountSimple
DTO
;
import
com.mmc.iuav.user.model.dto.
MenuInfo
DTO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.qo.RoleInfoQO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleInfoVO
;
import
com.mmc.iuav.user.model.vo.RoleMenuInfoVO
;
import
com.mmc.iuav.user.service.RoleService
;
import
com.mmc.iuav.user.service.RoleService
;
import
com.mmc.iuav.user.util.MenuTreeUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -38,7 +41,7 @@ public class RoleServiceImpl implements RoleService {
...
@@ -38,7 +41,7 @@ public class RoleServiceImpl implements RoleService {
}
}
RoleInfoDO
rd
=
new
RoleInfoDO
(
roleInfo
);
RoleInfoDO
rd
=
new
RoleInfoDO
(
roleInfo
);
rd
.
setUserAccountId
(
userLoginInfoFromRedis
.
getUserAccountId
());
rd
.
setUserAccountId
(
userLoginInfoFromRedis
.
getUserAccountId
());
rd
.
setRoleNo
(
CodeUtil
.
createRoleNo
());
rd
.
setRoleNo
(
CodeUtil
.
createRoleNo
(
roleDao
.
findList
()
));
roleDao
.
insertRoleInfo
(
rd
);
roleDao
.
insertRoleInfo
(
rd
);
return
ResultBody
.
success
();
return
ResultBody
.
success
();
}
}
...
@@ -80,11 +83,30 @@ public class RoleServiceImpl implements RoleService {
...
@@ -80,11 +83,30 @@ public class RoleServiceImpl implements RoleService {
}
}
@Override
@Override
public
ResultBody
roleAccountList
(
Integer
i
d
)
{
public
ResultBody
listRoleMenuInfo
(
Integer
roleI
d
)
{
List
<
UserAccountDO
>
roleInfoDOS
=
roleDao
.
roleAccountList
(
i
d
);
List
<
MenuInfoDO
>
menuInfoDOList
=
roleDao
.
listRoleMenuInfo
(
roleI
d
);
List
<
UserAccountSimpleDTO
>
accountSimpleDTOS
=
roleInfoDOS
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountSimple
DTO
).
collect
(
Collectors
.
toList
());
List
<
MenuInfoDTO
>
menuInfoDTOS
=
menuInfoDOList
.
stream
().
map
(
MenuInfoDO:
:
buildMenuInfo
DTO
).
collect
(
Collectors
.
toList
());
return
ResultBody
.
success
(
accountSimpleDTOS
);
return
ResultBody
.
success
(
MenuTreeUtil
.
buildTreePCMenu
(
menuInfoDTOS
)
);
}
}
@Override
public
ResultBody
updateRoleMenuInfo
(
RoleMenuInfoVO
roleMenuInfoVO
,
LoginSuccessDTO
userLoginInfoFromRedis
)
{
// 判断该角色的菜单是否可以修改
if
(!
CollectionUtils
.
isEmpty
(
roleMenuInfoVO
.
getMenuInfoIds
()))
{
List
<
MenuInfoDO
>
menuInfoDOList
=
roleDao
.
listRoleMenuInfo
(
roleMenuInfoVO
.
getRoleId
());
List
<
Integer
>
existMenuIds
=
menuInfoDOList
.
stream
().
map
(
MenuInfoDO:
:
getId
).
collect
(
Collectors
.
toList
());
// 新添加的权限
List
<
Integer
>
addMenuIds
=
roleMenuInfoVO
.
getMenuInfoIds
().
stream
().
filter
(
v
->
!
existMenuIds
.
contains
(
v
)).
collect
(
Collectors
.
toList
());
// 需删除的权限
List
<
Integer
>
deleteMenuIds
=
existMenuIds
.
stream
().
filter
(
v
->
!
roleMenuInfoVO
.
getMenuInfoIds
().
contains
(
v
)).
collect
(
Collectors
.
toList
());
if
(!
CollectionUtils
.
isEmpty
(
addMenuIds
))
{
roleDao
.
batchAddMenuIds
(
roleMenuInfoVO
.
getRoleId
(),
addMenuIds
);
}
if
(!
CollectionUtils
.
isEmpty
(
deleteMenuIds
))
{
roleDao
.
batchDeleteMenuIds
(
roleMenuInfoVO
.
getRoleId
(),
deleteMenuIds
);
}
}
return
ResultBody
.
success
();
}
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/service/impl/UserAccountServiceImpl.java
浏览文件 @
04e6346d
...
@@ -13,7 +13,10 @@ import com.mmc.iuav.user.entity.UserRcdDO;
...
@@ -13,7 +13,10 @@ import com.mmc.iuav.user.entity.UserRcdDO;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.dto.UserAccountSimpleDTO
;
import
com.mmc.iuav.user.model.qo.BUserAccountQO
;
import
com.mmc.iuav.user.model.qo.BUserAccountQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.qo.UserAccountQO
;
import
com.mmc.iuav.user.model.vo.*
;
import
com.mmc.iuav.user.model.vo.BUserAccountVO
;
import
com.mmc.iuav.user.model.vo.CompanyAuthVO
;
import
com.mmc.iuav.user.model.vo.CooperationTagVO
;
import
com.mmc.iuav.user.model.vo.UserAccountVO
;
import
com.mmc.iuav.user.mq.MqProducer
;
import
com.mmc.iuav.user.mq.MqProducer
;
import
com.mmc.iuav.user.service.CompanyAuthService
;
import
com.mmc.iuav.user.service.CompanyAuthService
;
import
com.mmc.iuav.user.service.UserAccountService
;
import
com.mmc.iuav.user.service.UserAccountService
;
...
@@ -74,7 +77,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -74,7 +77,7 @@ public class UserAccountServiceImpl implements UserAccountService {
CompanyAuthVO
companyAuthVO
=
companyAuthService
.
getCompanyAuthByUId
(
userAccountId
);
CompanyAuthVO
companyAuthVO
=
companyAuthService
.
getCompanyAuthByUId
(
userAccountId
);
if
(
companyAuthVO
!=
null
)
{
if
(
companyAuthVO
!=
null
)
{
userAccountVO
.
setCompanyAuthStatus
(
companyAuthVO
.
getAuthStatus
());
userAccountVO
.
setCompanyAuthStatus
(
companyAuthVO
.
getAuthStatus
());
}
else
{
}
else
{
userAccountVO
.
setCompanyAuthStatus
(
0
);
userAccountVO
.
setCompanyAuthStatus
(
0
);
}
}
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
...
@@ -96,18 +99,18 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -96,18 +99,18 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
UserAccountSimpleDTO
getUserSimpleInfo
(
Integer
userAccountId
)
{
public
UserAccountSimpleDTO
getUserSimpleInfo
(
Integer
userAccountId
)
{
UserAccountDO
userAccountDO
=
userServiceDao
.
getUserAccountById
(
userAccountId
);
UserAccountDO
userAccountDO
=
userServiceDao
.
getUserAccountById
(
userAccountId
);
if
(
userAccountDO
==
null
){
if
(
userAccountDO
==
null
)
{
return
null
;
return
null
;
}
}
UserAccountSimpleDTO
userAccountSimpleDTO
=
userAccountDO
.
buildUserAccountSimpleDTO
();
UserAccountSimpleDTO
userAccountSimpleDTO
=
userAccountDO
.
buildUserAccountSimpleDTO
();
CompanyAuthVO
companyAuthVO
=
companyAuthService
.
getCompanyAuthByUId
(
userAccountId
);
CompanyAuthVO
companyAuthVO
=
companyAuthService
.
getCompanyAuthByUId
(
userAccountId
);
if
(
companyAuthVO
!=
null
)
{
if
(
companyAuthVO
!=
null
)
{
userAccountSimpleDTO
.
setCompanyAuthStatus
(
companyAuthVO
.
getAuthStatus
());
userAccountSimpleDTO
.
setCompanyAuthStatus
(
companyAuthVO
.
getAuthStatus
());
}
else
{
}
else
{
userAccountSimpleDTO
.
setCompanyAuthStatus
(
0
);
userAccountSimpleDTO
.
setCompanyAuthStatus
(
0
);
}
}
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
))
{
List
<
CooperationTagVO
>
cooperationTags
=
cooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
List
<
CooperationTagVO
>
cooperationTags
=
cooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
userAccountSimpleDTO
.
setCooperationTagVOS
(
cooperationTags
);
userAccountSimpleDTO
.
setCooperationTagVOS
(
cooperationTags
);
}
}
...
@@ -184,15 +187,15 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -184,15 +187,15 @@ public class UserAccountServiceImpl implements UserAccountService {
return
accountSimpleDTOS
;
return
accountSimpleDTOS
;
}
}
public
void
buildCooperationTagVO
(
List
<
UserAccountSimpleDTO
>
accountSimpleDTOS
){
public
void
buildCooperationTagVO
(
List
<
UserAccountSimpleDTO
>
accountSimpleDTOS
)
{
List
<
Integer
>
uIds
=
accountSimpleDTOS
.
stream
().
map
(
UserAccountSimpleDTO:
:
getId
).
collect
(
Collectors
.
toList
());
List
<
Integer
>
uIds
=
accountSimpleDTOS
.
stream
().
map
(
UserAccountSimpleDTO:
:
getId
).
collect
(
Collectors
.
toList
());
//设置用户的渠道等级
//设置用户的渠道等级
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTagByUIds
(
uIds
);
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTagByUIds
(
uIds
);
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
))
{
Map
<
Integer
,
List
<
CooperationTagDO
>>
userTagsMap
=
cooperationTagDOS
.
stream
().
collect
(
Collectors
.
groupingBy
(
CooperationTagDO:
:
getUserAccountId
));
Map
<
Integer
,
List
<
CooperationTagDO
>>
userTagsMap
=
cooperationTagDOS
.
stream
().
collect
(
Collectors
.
groupingBy
(
CooperationTagDO:
:
getUserAccountId
));
for
(
UserAccountSimpleDTO
simpleDTO
:
accountSimpleDTOS
)
{
for
(
UserAccountSimpleDTO
simpleDTO
:
accountSimpleDTOS
)
{
List
<
CooperationTagDO
>
tagDOS
=
userTagsMap
.
get
(
simpleDTO
.
getId
());
List
<
CooperationTagDO
>
tagDOS
=
userTagsMap
.
get
(
simpleDTO
.
getId
());
if
(!
CollectionUtils
.
isEmpty
(
tagDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
tagDOS
))
{
List
<
CooperationTagVO
>
cooperationTagVOS
=
tagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
List
<
CooperationTagVO
>
cooperationTagVOS
=
tagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
simpleDTO
.
setCooperationTagVOS
(
cooperationTagVOS
);
simpleDTO
.
setCooperationTagVOS
(
cooperationTagVOS
);
}
}
...
@@ -253,7 +256,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -253,7 +256,7 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
ResultBody
getUserPhoneNumber
(
Integer
id
,
String
code
)
{
public
ResultBody
getUserPhoneNumber
(
Integer
id
,
String
code
)
{
String
userPhoneNumber
=
wxService
.
getUserPhoneNumber
(
id
,
code
);
String
userPhoneNumber
=
wxService
.
getUserPhoneNumber
(
id
,
code
);
if
(
StringUtils
.
isBlank
(
userPhoneNumber
)){
if
(
StringUtils
.
isBlank
(
userPhoneNumber
))
{
return
ResultBody
.
error
(
ResultEnum
.
AUTH_PHONE_NUMBER_ERROR
);
return
ResultBody
.
error
(
ResultEnum
.
AUTH_PHONE_NUMBER_ERROR
);
}
}
UserAccountDO
userAccount
=
new
UserAccountDO
();
UserAccountDO
userAccount
=
new
UserAccountDO
();
...
@@ -266,7 +269,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -266,7 +269,7 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
List
<
UserAccountSimpleDTO
>
feignListUserAccountByIds
(
List
<
Integer
>
ids
)
{
public
List
<
UserAccountSimpleDTO
>
feignListUserAccountByIds
(
List
<
Integer
>
ids
)
{
List
<
UserAccountDO
>
userAccountDOS
=
userServiceDao
.
listUserAccountByIds
(
ids
);
List
<
UserAccountDO
>
userAccountDOS
=
userServiceDao
.
listUserAccountByIds
(
ids
);
if
(!
CollectionUtils
.
isEmpty
(
userAccountDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
userAccountDOS
))
{
List
<
UserAccountSimpleDTO
>
userAccountSimpleDTOS
=
userAccountDOS
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountSimpleDTO
).
collect
(
Collectors
.
toList
());
List
<
UserAccountSimpleDTO
>
userAccountSimpleDTOS
=
userAccountDOS
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountSimpleDTO
).
collect
(
Collectors
.
toList
());
//设置用户的渠道等级
//设置用户的渠道等级
buildCooperationTagVO
(
userAccountSimpleDTOS
);
buildCooperationTagVO
(
userAccountSimpleDTOS
);
...
@@ -278,7 +281,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -278,7 +281,7 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
List
<
UserAccountSimpleDTO
>
feignListRcdUserInfo
(
List
<
Integer
>
userIds
)
{
public
List
<
UserAccountSimpleDTO
>
feignListRcdUserInfo
(
List
<
Integer
>
userIds
)
{
List
<
UserAccountDO
>
userAccountDOS
=
userServiceDao
.
feignListRcdUserInfo
(
userIds
);
List
<
UserAccountDO
>
userAccountDOS
=
userServiceDao
.
feignListRcdUserInfo
(
userIds
);
if
(!
CollectionUtils
.
isEmpty
(
userAccountDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
userAccountDOS
))
{
List
<
UserAccountSimpleDTO
>
userAccountSimpleDTOS
=
userAccountDOS
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountSimpleDTO
).
collect
(
Collectors
.
toList
());
List
<
UserAccountSimpleDTO
>
userAccountSimpleDTOS
=
userAccountDOS
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountSimpleDTO
).
collect
(
Collectors
.
toList
());
//设置用户的渠道等级
//设置用户的渠道等级
buildCooperationTagVO
(
userAccountSimpleDTOS
);
buildCooperationTagVO
(
userAccountSimpleDTOS
);
...
@@ -290,7 +293,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -290,7 +293,7 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
Integer
feignGetSuperiorRef
(
Integer
userAccountId
)
{
public
Integer
feignGetSuperiorRef
(
Integer
userAccountId
)
{
UserRcdDO
userRcdDO
=
userServiceDao
.
getUserRcdDO
(
userAccountId
);
UserRcdDO
userRcdDO
=
userServiceDao
.
getUserRcdDO
(
userAccountId
);
if
(
userRcdDO
!=
null
){
if
(
userRcdDO
!=
null
)
{
return
userRcdDO
.
getId
();
return
userRcdDO
.
getId
();
}
}
return
null
;
return
null
;
...
@@ -299,10 +302,10 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -299,10 +302,10 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
UserAccountSimpleDTO
feignGetUserRcdInfo
(
Integer
userAccountId
)
{
public
UserAccountSimpleDTO
feignGetUserRcdInfo
(
Integer
userAccountId
)
{
UserAccountDO
rcdAccountDO
=
userServiceDao
.
getUserRcdByAccountId
(
userAccountId
);
UserAccountDO
rcdAccountDO
=
userServiceDao
.
getUserRcdByAccountId
(
userAccountId
);
if
(
rcdAccountDO
!=
null
){
if
(
rcdAccountDO
!=
null
)
{
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
List
<
CooperationTagDO
>
cooperationTagDOS
=
cooperationDao
.
listUserCooperationTag
(
userAccountId
);
UserAccountSimpleDTO
userAccountSimpleDTO
=
rcdAccountDO
.
buildUserAccountSimpleDTO
();
UserAccountSimpleDTO
userAccountSimpleDTO
=
rcdAccountDO
.
buildUserAccountSimpleDTO
();
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
cooperationTagDOS
))
{
List
<
CooperationTagVO
>
cooperationTagVOS
=
cooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
List
<
CooperationTagVO
>
cooperationTagVOS
=
cooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
userAccountSimpleDTO
.
setCooperationTagVOS
(
cooperationTagVOS
);
userAccountSimpleDTO
.
setCooperationTagVOS
(
cooperationTagVOS
);
}
}
...
@@ -314,7 +317,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -314,7 +317,7 @@ public class UserAccountServiceImpl implements UserAccountService {
@Override
@Override
public
ResultBody
listAppUser
(
UserAccountQO
param
)
{
public
ResultBody
listAppUser
(
UserAccountQO
param
)
{
int
count
=
userServiceDao
.
countListAppUser
(
param
);
int
count
=
userServiceDao
.
countListAppUser
(
param
);
if
(
count
==
0
){
if
(
count
==
0
)
{
return
ResultBody
.
success
(
PageResult
.
buildPage
(
param
.
getPageNo
(),
param
.
getPageSize
(),
count
));
return
ResultBody
.
success
(
PageResult
.
buildPage
(
param
.
getPageNo
(),
param
.
getPageSize
(),
count
));
}
}
int
pageNo
=
param
.
getPageNo
();
int
pageNo
=
param
.
getPageNo
();
...
@@ -327,7 +330,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -327,7 +330,7 @@ public class UserAccountServiceImpl implements UserAccountService {
List
<
UserAccountVO
>
userAccountVOS
=
res
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountVO
).
collect
(
Collectors
.
toList
());
List
<
UserAccountVO
>
userAccountVOS
=
res
.
stream
().
map
(
UserAccountDO:
:
buildUserAccountVO
).
collect
(
Collectors
.
toList
());
for
(
UserAccountVO
userAccountVO
:
userAccountVOS
)
{
for
(
UserAccountVO
userAccountVO
:
userAccountVOS
)
{
List
<
CooperationTagDO
>
userCooperationTagDOS
=
userTagsMap
.
get
(
userAccountVO
.
getId
());
List
<
CooperationTagDO
>
userCooperationTagDOS
=
userTagsMap
.
get
(
userAccountVO
.
getId
());
if
(!
CollectionUtils
.
isEmpty
(
userCooperationTagDOS
)){
if
(!
CollectionUtils
.
isEmpty
(
userCooperationTagDOS
))
{
List
<
CooperationTagVO
>
cooperationTagVOS
=
userCooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
List
<
CooperationTagVO
>
cooperationTagVOS
=
userCooperationTagDOS
.
stream
().
map
(
CooperationTagDO:
:
buildCooperationTagVO
).
collect
(
Collectors
.
toList
());
userAccountVO
.
setCooperationTagVOS
(
cooperationTagVOS
);
userAccountVO
.
setCooperationTagVOS
(
cooperationTagVOS
);
}
}
...
@@ -350,7 +353,7 @@ public class UserAccountServiceImpl implements UserAccountService {
...
@@ -350,7 +353,7 @@ public class UserAccountServiceImpl implements UserAccountService {
Map
<
Integer
,
CooperationTagDO
>
cooperationTagDOMap
=
cooperationTagDOS
.
stream
().
collect
(
Collectors
.
toMap
(
CooperationTagDO:
:
getId
,
d
->
d
,
(
k1
,
k2
)
->
k2
));
Map
<
Integer
,
CooperationTagDO
>
cooperationTagDOMap
=
cooperationTagDOS
.
stream
().
collect
(
Collectors
.
toMap
(
CooperationTagDO:
:
getId
,
d
->
d
,
(
k1
,
k2
)
->
k2
));
for
(
UserAccountDO
userAccountDO
:
userAccountDOList
)
{
for
(
UserAccountDO
userAccountDO
:
userAccountDOList
)
{
CooperationTagDO
cooperationTagDO
=
cooperationTagDOMap
.
get
(
userAccountDO
.
getCooperationTagId
());
CooperationTagDO
cooperationTagDO
=
cooperationTagDOMap
.
get
(
userAccountDO
.
getCooperationTagId
());
if
(
cooperationTagDO
!=
null
){
if
(
cooperationTagDO
!=
null
)
{
userAccountDO
.
setTagName
(
cooperationTagDO
.
getTagName
());
userAccountDO
.
setTagName
(
cooperationTagDO
.
getTagName
());
}
}
}
}
...
...
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/util/MenuTreeUtil.java
浏览文件 @
04e6346d
...
@@ -9,8 +9,8 @@ import java.util.List;
...
@@ -9,8 +9,8 @@ import java.util.List;
* @author zj
* @author zj
*/
*/
public
class
MenuTreeUtil
{
public
class
MenuTreeUtil
{
public
final
static
Integer
SXTB
_PC_MENU_PID
=
1
;
public
final
static
Integer
IUAV
_PC_MENU_PID
=
1
;
public
final
static
String
SXTB
_PC_MENU_NAME
=
"云享飞管理后台"
;
public
final
static
String
IUAV
_PC_MENU_NAME
=
"云享飞管理后台"
;
public
static
void
builderTree
(
List
<
MenuInfoDTO
>
treeEntityList
,
MenuInfoDTO
pTreeEntity
)
{
public
static
void
builderTree
(
List
<
MenuInfoDTO
>
treeEntityList
,
MenuInfoDTO
pTreeEntity
)
{
List
<
MenuInfoDTO
>
childMenus
=
new
ArrayList
<
MenuInfoDTO
>();
List
<
MenuInfoDTO
>
childMenus
=
new
ArrayList
<
MenuInfoDTO
>();
...
@@ -46,8 +46,8 @@ public class MenuTreeUtil {
...
@@ -46,8 +46,8 @@ public class MenuTreeUtil {
*/
*/
public
static
MenuInfoDTO
buildTreePCMenu
(
List
<
MenuInfoDTO
>
treeEntityList
)
{
public
static
MenuInfoDTO
buildTreePCMenu
(
List
<
MenuInfoDTO
>
treeEntityList
)
{
MenuInfoDTO
parent
=
new
MenuInfoDTO
();
MenuInfoDTO
parent
=
new
MenuInfoDTO
();
parent
.
setId
(
MenuTreeUtil
.
SXTB
_PC_MENU_PID
);
parent
.
setId
(
MenuTreeUtil
.
IUAV
_PC_MENU_PID
);
parent
.
setMenuName
(
SXTB
_PC_MENU_NAME
);
parent
.
setMenuName
(
IUAV
_PC_MENU_NAME
);
MenuTreeUtil
.
builderTree
(
treeEntityList
,
parent
);
MenuTreeUtil
.
builderTree
(
treeEntityList
,
parent
);
return
parent
;
return
parent
;
}
}
...
...
csm-service/cms-service-user/src/main/resources/mapper/BackUserAccountDao.xml
浏览文件 @
04e6346d
...
@@ -21,9 +21,12 @@
...
@@ -21,9 +21,12 @@
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
</resultMap>
</resultMap>
<insert
id=
"insertBackUserAccount"
parameterType=
"com.mmc.iuav.user.entity.BackUserAccountDO"
keyProperty=
"id"
useGeneratedKeys=
"true"
>
<insert
id=
"insertBackUserAccount"
parameterType=
"com.mmc.iuav.user.entity.BackUserAccountDO"
keyProperty=
"id"
insert into back_user_account( account_no, pass_word, phone_num, user_name, user_sex, email, province_code, city_code, district_code, address, remark, create_time)
useGeneratedKeys=
"true"
>
values(#{accountNo}, #{password}, #{phoneNum}, #{userName}, #{userSex}, #{email}, #{provinceCode}, #{cityCode}, #{districtCode}, #{address}, #{remark}, NOW())
insert into back_user_account(account_no, pass_word, phone_num, user_name, user_sex, email, province_code,
city_code, district_code, address, remark, create_time)
values (#{accountNo}, #{password}, #{phoneNum}, #{userName}, #{userSex}, #{email}, #{provinceCode}, #{cityCode},
#{districtCode}, #{address}, #{remark}, NOW())
</insert>
</insert>
<update
id=
"updateBackUserAccount"
>
<update
id=
"updateBackUserAccount"
>
...
@@ -69,64 +72,111 @@
...
@@ -69,64 +72,111 @@
</update>
</update>
<update
id=
"removeBackUserAccountDO"
>
<update
id=
"removeBackUserAccountDO"
>
update back_user_account set is_deleted = 1 where is_deleted = 0 and id = #{id}
update back_user_account
set is_deleted = 1
where is_deleted = 0
and id = #{id}
</update>
</update>
<update
id=
"updatePassword"
>
<update
id=
"updatePassword"
>
update back_user_account set pass_word = #{passWord} where id = #{id}
update back_user_account
set pass_word = #{passWord}
where id = #{id}
</update>
</update>
<select
id=
"getBackUserAccountDO"
resultType=
"com.mmc.iuav.user.entity.BackUserAccountDO"
>
<select
id=
"getBackUserAccountDO"
resultType=
"com.mmc.iuav.user.entity.BackUserAccountDO"
>
select id, account_no, phone_num, user_name, user_sex, email, account_status, remark, province_code, city_code, district_code, address, is_deleted, create_time, update_time
select id,
account_no,
phone_num,
user_name,
user_sex,
email,
account_status,
remark,
province_code,
city_code,
district_code,
address,
is_deleted,
create_time,
update_time
from back_user_account
from back_user_account
where id = #{id}
where id = #{id}
</select>
</select>
<select
id=
"countListBackUserAccount"
resultType=
"java.lang.Integer"
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
<select
id=
"countListBackUserAccount"
resultType=
"java.lang.Integer"
select count(*) from back_user_account
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
where is_deleted = 0
select count(*) from back_user_account bua
left join user_role_rel urr on urr.user_account_id=bua.id
where bua.is_deleted = 0
<if
test=
" keyword != null and keyword != '' "
>
<if
test=
" keyword != null and keyword != '' "
>
and ( account_no like CONCAT("%",#{keyword},"%") or
and (
bua.
account_no like CONCAT("%",#{keyword},"%") or
user_name like CONCAT("%",#{keyword},"%") )
bua.
user_name like CONCAT("%",#{keyword},"%") )
</if>
</if>
<if
test=
"provinceCode != null"
>
<if
test=
"provinceCode != null"
>
and province_code = #{provinceCode}
and
bua.
province_code = #{provinceCode}
</if>
</if>
<if
test=
"cityCode != null"
>
<if
test=
"cityCode != null"
>
and city_code = #{cityCode}
and
bua.
city_code = #{cityCode}
</if>
</if>
<if
test=
"districtCode != null"
>
<if
test=
"districtCode != null"
>
and district_code = #{districtCode}
and
bua.
district_code = #{districtCode}
</if>
</if>
<if
test=
"accountStatus != null"
>
<if
test=
"accountStatus != null"
>
and account_status = #{accountStatus}
and bua.account_status = #{accountStatus}
</if>
<if
test=
"roleId != null"
>
and urr.role_id = #{roleId}
</if>
</if>
</select>
</select>
<select
id=
"listBackUserAccount"
resultMap=
"backUserAccountResultMap"
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
<select
id=
"listBackUserAccount"
resultMap=
"backUserAccountResultMap"
select id, account_no, phone_num, user_name, user_sex, email, account_status, province_code, city_code, district_code, address, remark, create_time, update_time
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
from back_user_account
SELECT
where is_deleted = 0
bua.id,
bua.account_no,
bua.phone_num,
bua.user_name,
bua.user_sex,
bua.email,
bua.account_status,
bua.province_code,
bua.city_code,
bua.district_code,
bua.address,
bua.remark,
bua.create_time,
bua.update_time
FROM
back_user_account bua
left join user_role_rel urr on urr.user_account_id=bua.id
WHERE
bua.is_deleted = 0
<if
test=
" keyword != null and keyword != '' "
>
<if
test=
" keyword != null and keyword != '' "
>
and ( account_no like CONCAT("%",#{keyword},"%") or
and (
bua.
account_no like CONCAT("%",#{keyword},"%") or
user_name like CONCAT("%",#{keyword},"%") )
bua.
user_name like CONCAT("%",#{keyword},"%") )
</if>
</if>
<if
test=
"provinceCode != null"
>
<if
test=
"provinceCode != null"
>
and province_code = #{provinceCode}
and
bua.
province_code = #{provinceCode}
</if>
</if>
<if
test=
"cityCode != null"
>
<if
test=
"cityCode != null"
>
and city_code = #{cityCode}
and
bua.
city_code = #{cityCode}
</if>
</if>
<if
test=
"districtCode != null"
>
<if
test=
"districtCode != null"
>
and district_code = #{districtCode}
and
bua.
district_code = #{districtCode}
</if>
</if>
<if
test=
"accountStatus != null"
>
<if
test=
"accountStatus != null"
>
and account_status = #{accountStatus}
and bua.account_status = #{accountStatus}
</if>
<if
test=
"roleId != null"
>
and urr.role_id = #{roleId}
</if>
</if>
</select>
</select>
<select
id=
"feignListBackUserAccount"
resultMap=
"backUserAccountResultMap"
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
<select
id=
"feignListBackUserAccount"
resultMap=
"backUserAccountResultMap"
select ua.id, ua.account_no, ua.phone_num, ua.user_name, ua.user_sex, ua.email, ua.account_status, ua.remark, ua.is_deleted as deleted, ua.create_time, ua.update_time
parameterType=
"com.mmc.iuav.user.model.qo.BUserAccountQO"
>
select ua.id, ua.account_no, ua.phone_num, ua.user_name, ua.user_sex, ua.email, ua.account_status, ua.remark,
ua.is_deleted as deleted, ua.create_time, ua.update_time
from back_user_account ua
from back_user_account ua
where ua.is_deleted = 0
where ua.is_deleted = 0
<if
test=
" userIds != null "
>
<if
test=
" userIds != null "
>
...
@@ -181,4 +231,4 @@
...
@@ -181,4 +231,4 @@
</if>
</if>
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
csm-service/cms-service-user/src/main/resources/mapper/MenuInfoDao.xml
浏览文件 @
04e6346d
...
@@ -3,39 +3,6 @@
...
@@ -3,39 +3,6 @@
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.mmc.iuav.user.dao.MenuInfoDao"
>
<mapper
namespace=
"com.mmc.iuav.user.dao.MenuInfoDao"
>
<resultMap
id=
"menuInfoResultMap"
type=
"com.mmc.iuav.user.entity.MenuInfoDO"
>
<id
property=
"id"
column=
"id"
/>
<result
property=
"pid"
column=
"pid"
/>
<result
property=
"menuName"
column=
"menu_name"
/>
<result
property=
"portType"
column=
"port_type"
/>
<result
property=
"domType"
column=
"dom_type"
/>
<result
property=
"pathInfo"
column=
"path_info"
/>
<result
property=
"icon"
column=
"icon"
/>
<result
property=
"sort"
column=
"sort"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
</resultMap>
<insert
id=
"batchAddMenuIds"
>
insert into menu_role_rel
(
role_id,menu_id,create_time
)
values
<foreach
collection=
"addMenuIds"
item=
"menuId"
separator=
","
>
(
#{roleId},#{menuId},NOW()
)
</foreach>
</insert>
<delete
id=
"batchDeleteMenuIds"
>
delete from menu_role_rel where role_id = #{roleId} and menu_id in
<foreach
collection=
"deleteMenuIds"
item=
"menuId"
open=
"("
separator=
","
close=
")"
>
#{menuId}
</foreach>
</delete>
<select
id=
"listMenuInfo"
resultType=
"com.mmc.iuav.user.entity.MenuInfoDO"
>
<select
id=
"listMenuInfo"
resultType=
"com.mmc.iuav.user.entity.MenuInfoDO"
>
select m.id,m.pid,m.menu_name,m.dom_type,m.path_info
select m.id,m.pid,m.menu_name,m.dom_type,m.path_info
...
@@ -43,12 +10,4 @@
...
@@ -43,12 +10,4 @@
order by m.sort ASC
order by m.sort ASC
</select>
</select>
<select
id=
"listRoleMenuInfo"
resultType=
"com.mmc.iuav.user.entity.MenuInfoDO"
>
select m.id,m.pid,m.menu_name,m.dom_type,m.path_info
from menu_info m
inner join menu_role_rel mr on mr.menu_id=m.id
where mr.role_id = #{roleId}
order by m.sort ASC
</select>
</mapper>
</mapper>
\ No newline at end of file
csm-service/cms-service-user/src/main/resources/mapper/RoleDao.xml
浏览文件 @
04e6346d
...
@@ -18,6 +18,7 @@
...
@@ -18,6 +18,7 @@
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"superAdmin"
column=
"super_admin"
/>
</resultMap>
</resultMap>
...
@@ -65,10 +66,22 @@
...
@@ -65,10 +66,22 @@
<insert
id=
"insertRoleInfo"
useGeneratedKeys=
"true"
<insert
id=
"insertRoleInfo"
useGeneratedKeys=
"true"
keyProperty=
"id"
parameterType=
"com.mmc.iuav.user.entity.RoleInfoDO"
>
keyProperty=
"id"
parameterType=
"com.mmc.iuav.user.entity.RoleInfoDO"
>
insert into role_info(role_no, role_name, user_account_id, remark, create_time)
insert into role_info(role_no, role_name, user_account_id, remark, create_time
, update_time
)
values (#{roleNo}, #{roleName}, #{userAccountId}, #{remark}, NOW())
values (#{roleNo}, #{roleName}, #{userAccountId}, #{remark}, NOW()
, NOW()
)
</insert>
</insert>
<insert
id=
"batchAddMenuIds"
>
insert into menu_role_rel
(
role_id,menu_id,create_time
)
values
<foreach
collection=
"addMenuIds"
item=
"menuId"
separator=
","
>
(
#{roleId},#{menuId},NOW()
)
</foreach>
</insert>
<update
id=
"updateRoleInfo"
<update
id=
"updateRoleInfo"
parameterType=
"com.mmc.iuav.user.entity.RoleInfoDO"
>
parameterType=
"com.mmc.iuav.user.entity.RoleInfoDO"
>
...
@@ -90,13 +103,19 @@
...
@@ -90,13 +103,19 @@
where role_id = #{roleId}
where role_id = #{roleId}
</select>
</select>
<update
id=
"removeRoleInfo"
parameterType=
"int"
>
<delete
id=
"removeRoleInfo"
parameterType=
"java.lang.Integer"
>
UPDATE role_info
delete
<set>
from role_info
is_deleted = 1
</set>
where id = #{id}
where id = #{id}
</update>
</delete>
<delete
id=
"batchDeleteMenuIds"
>
delete from menu_role_rel where role_id = #{roleId} and menu_id in
<foreach
collection=
"deleteMenuIds"
item=
"menuId"
open=
"("
separator=
","
close=
")"
>
#{menuId}
</foreach>
</delete>
<select
id=
"getRoleInfo"
resultMap=
"roleInfoResultMap"
<select
id=
"getRoleInfo"
resultMap=
"roleInfoResultMap"
parameterType=
"int"
>
parameterType=
"int"
>
...
@@ -115,7 +134,7 @@
...
@@ -115,7 +134,7 @@
SELECT count(*)
SELECT count(*)
FROM
FROM
role_info r
role_info r
INNER JOIN user_account ua ON r.user_account_id = ua.id
INNER JOIN
back_
user_account ua ON r.user_account_id = ua.id
WHERE
WHERE
r.is_deleted =0
r.is_deleted =0
<if
test=
" NumberOrName != null and NumberOrName != '' "
>
<if
test=
" NumberOrName != null and NumberOrName != '' "
>
...
@@ -134,11 +153,12 @@
...
@@ -134,11 +153,12 @@
r.remark,
r.remark,
r.create_time,
r.create_time,
r.user_account_id,
r.user_account_id,
r.super_admin,
ua.user_name,
ua.user_name,
r.update_time
r.update_time
FROM
FROM
role_info r
role_info r
INNER JOIN user_account ua ON r.user_account_id = ua.id
INNER JOIN
back_
user_account ua ON r.user_account_id = ua.id
WHERE
WHERE
r.is_deleted =0
r.is_deleted =0
<if
test=
" NumberOrName != null and NumberOrName != '' "
>
<if
test=
" NumberOrName != null and NumberOrName != '' "
>
...
@@ -157,16 +177,20 @@
...
@@ -157,16 +177,20 @@
AND ua.is_deleted = 0
AND ua.is_deleted = 0
</select>
</select>
<select
id=
"roleAccountList"
resultMap=
"userAccountResultMap"
>
<select
id=
"listRoleMenuInfo"
resultType=
"com.mmc.iuav.user.entity.MenuInfoDO"
>
SELECT urr.user_account_id,
select m.id, m.pid, m.menu_name, m.dom_type, m.path_info
ua.user_name,
from menu_info m
ua.uid,
inner join menu_role_rel mr on mr.menu_id = m.id
ua.phone_num,
where mr.role_id = #{roleId}
ua.user_name,
order by m.sort ASC
ua.is_deleted
</select>
FROM user_role_rel urr
LEFT JOIN user_account ua ON ua.id = urr.user_account_id
<select
id=
"findList"
resultType=
"java.lang.String"
>
WHERE urr.role_id = #{id}
SELECT role_no
AND ua.is_deleted = 0
FROM role_info
where is_deleted = 0
ORDER BY id DESC LIMIT 1;
</select>
</select>
</mapper>
</mapper>
csm-service/cms-service-user/src/main/resources/mapper/UserServiceDao.xml
浏览文件 @
04e6346d
差异被折叠。
点击展开。
kustomization/overlays/dev/kustomization.yaml
浏览文件 @
04e6346d
...
@@ -18,4 +18,4 @@ patches:
...
@@ -18,4 +18,4 @@ patches:
images
:
images
:
-
name
:
REGISTRY/NAMESPACE/IMAGE:TAG
-
name
:
REGISTRY/NAMESPACE/IMAGE:TAG
newName
:
mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/cms
newName
:
mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/cms
newTag
:
9b3bd9bc0f9cdefd5cdfedd1a0e7c575252b33e4
newTag
:
4226adde5a2173ccfa143e69df821d3d19a368a0
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论