|
|
@@ -2,6 +2,7 @@ package com.tuoheng.admin.service.system.role; |
|
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.convert.Convert; |
|
|
|
import cn.hutool.core.io.unit.DataUnit; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
@@ -90,7 +91,7 @@ public class RoleServiceImpl implements IRoleService { |
|
|
|
} |
|
|
|
queryWrapper.eq("mark", MarkEnum.VALID.getCode()); |
|
|
|
//queryWrapper.orderByAsc("sort"); |
|
|
|
queryWrapper.orderByDesc("create_time"); |
|
|
|
queryWrapper.orderByDesc("update_time"); |
|
|
|
queryWrapper.ne("id", "1"); |
|
|
|
// 查询分页数据 |
|
|
|
IPage<Role> pageData = roleMapper.selectPage(page, queryWrapper); |
|
|
@@ -144,6 +145,8 @@ public class RoleServiceImpl implements IRoleService { |
|
|
|
entity.setTenantId(CurrentUserUtil.getTenantId()); |
|
|
|
entity.setCreateUser(CurrentUserUtil.getUserId()); |
|
|
|
entity.setCreateTime(DateUtils.now()); |
|
|
|
entity.setUpdateTime(DateUtils.now()); |
|
|
|
entity.setUpdateUser(CurrentUserUtil.getUserId()); |
|
|
|
} |
|
|
|
if (entity == null) { |
|
|
|
return JsonResult.error("实体对象不存在"); |