mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-08-08 23:31:53 +08:00
✅ 增加 permission 模块的单测覆盖率
This commit is contained in:
@@ -48,7 +48,7 @@ public interface NotifySendService {
|
||||
String templateCode, Map<String, Object> templateParams);
|
||||
|
||||
default void sendBatchNotify(List<String> mobiles, List<Long> userIds, Integer userType,
|
||||
String templateCode, Map<String, Object> templateParams) {
|
||||
String templateCode, Map<String, Object> templateParams) {
|
||||
throw new UnsupportedOperationException("暂时不支持该操作,感兴趣可以实现该功能哟!");
|
||||
}
|
||||
|
||||
|
@@ -6,6 +6,7 @@ import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.extra.spring.SpringUtil;
|
||||
import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum;
|
||||
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||
import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils;
|
||||
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||
import cn.iocoder.yudao.module.system.controller.admin.permission.vo.role.RolePageReqVO;
|
||||
import cn.iocoder.yudao.module.system.controller.admin.permission.vo.role.RoleSaveReqVO;
|
||||
@@ -27,7 +28,6 @@ import javax.annotation.Resource;
|
||||
import java.util.*;
|
||||
|
||||
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMap;
|
||||
import static cn.iocoder.yudao.module.system.enums.ErrorCodeConstants.*;
|
||||
|
||||
@@ -198,7 +198,7 @@ public class RoleServiceImpl implements RoleService {
|
||||
}
|
||||
// 这里采用 for 循环从缓存中获取,主要考虑 Spring CacheManager 无法批量操作的问题
|
||||
RoleServiceImpl self = getSelf();
|
||||
return convertList(ids, self::getRoleFromCache);
|
||||
return CollectionUtils.convertList(ids, self::getRoleFromCache);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@@ -1,49 +0,0 @@
|
||||
package cn.iocoder.yudao.module.system.service.permission.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Size;
|
||||
|
||||
/**
|
||||
* 角色创建 Request BO
|
||||
*
|
||||
* @author 芋道源码
|
||||
*/
|
||||
@Data
|
||||
public class RoleCreateReqBO {
|
||||
|
||||
/**
|
||||
* 租户编号
|
||||
*/
|
||||
@NotNull(message = "租户编号不能为空")
|
||||
private Long tenantId;
|
||||
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
@NotBlank(message = "角色名称不能为空")
|
||||
@Size(max = 30, message = "角色名称长度不能超过30个字符")
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 角色标志
|
||||
*/
|
||||
@NotBlank(message = "角色标志不能为空")
|
||||
@Size(max = 100, message = "角色标志长度不能超过100个字符")
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 显示顺序
|
||||
*/
|
||||
@NotNull(message = "显示顺序不能为空")
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 角色类型
|
||||
*/
|
||||
@NotNull(message = "角色类型不能为空")
|
||||
private Integer type;
|
||||
|
||||
}
|
Reference in New Issue
Block a user