|
@@ -9,10 +9,7 @@ import cn.newfeifan.mall.module.system.dal.dataobject.permission.RoleDO;
|
|
|
import org.apache.ibatis.annotations.Mapper;
|
|
|
import org.springframework.lang.Nullable;
|
|
|
|
|
|
-import java.util.ArrayList;
|
|
|
-import java.util.Collection;
|
|
|
-import java.util.List;
|
|
|
-import java.util.Set;
|
|
|
+import java.util.*;
|
|
|
|
|
|
@Mapper
|
|
|
public interface RoleMapper extends BaseMapperX<RoleDO> {
|
|
@@ -39,6 +36,9 @@ public interface RoleMapper extends BaseMapperX<RoleDO> {
|
|
|
return selectList(RoleDO::getStatus, statuses);
|
|
|
}
|
|
|
default List<String> selectByRoleIds(Set<Long> roleIds){
|
|
|
+ if (roleIds.isEmpty()) {
|
|
|
+ return Collections.emptyList();
|
|
|
+ }
|
|
|
List<RoleDO> roleDOS = selectList(new LambdaQueryWrapperX<RoleDO>()
|
|
|
.inIfPresent(RoleDO::getId, roleIds));
|
|
|
List<String> strings = new ArrayList<>();
|