代码优化
This commit is contained in:
parent
057a45d065
commit
159bde0779
@ -64,7 +64,7 @@ public class EbikeStatisticsController {
|
|||||||
boolean isSuperAdmin = Optional.ofNullable(staffInfo.getRoles())
|
boolean isSuperAdmin = Optional.ofNullable(staffInfo.getRoles())
|
||||||
.orElse(Collections.emptyList())
|
.orElse(Collections.emptyList())
|
||||||
.stream()
|
.stream()
|
||||||
.anyMatch(role -> "super_admin".equals(role.getRoleCode()));
|
.anyMatch(CommonEbikeRole::getSysAdmin);
|
||||||
// 判断是否超级管理员
|
// 判断是否超级管理员
|
||||||
if (!isSuperAdmin) {
|
if (!isSuperAdmin) {
|
||||||
dto.setOperatorId(staffInfo.getOperatorId());
|
dto.setOperatorId(staffInfo.getOperatorId());
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user