commit
This commit is contained in:
@@ -50,17 +50,7 @@ public class SysV4AppsController {
|
||||
@SaCheckLogin
|
||||
@ApiOperation("获取应用分类")
|
||||
public Result categories(@Param(value = "platform", df = "PC") String platform) {
|
||||
List<Sys_module> list;
|
||||
if (AuthUtil.hasRoleOr(RoleConstant.SYSADMIN.name(), RoleConstant.SCHOOL_UNION_ADMIN.name())) {
|
||||
list = dao.query(Sys_module.class, Cnd.where(Sys_module::getPlatform, "=", platform).asc(Sys_module::getSortNum));
|
||||
} else {
|
||||
list = dao.query(
|
||||
Sys_module.class,
|
||||
Cnd.where(Sys_module::getPlatform, "=", platform)
|
||||
.and(Sys_module::getId, "=", "2")
|
||||
.asc(Sys_module::getSortNum)
|
||||
);
|
||||
}
|
||||
List<Sys_module> list = dao.query(Sys_module.class, Cnd.where(Sys_module::getPlatform, "=", platform).asc(Sys_module::getSortNum));
|
||||
List<Map<String, Object>> categories = list.stream().map(module -> {
|
||||
Map<String, Object> category = new HashMap<>();
|
||||
category.put("id", module.getId());
|
||||
|
||||
Reference in New Issue
Block a user