权限管理
This commit is contained in:
@@ -20,6 +20,8 @@ public interface SecurityConstant {
|
||||
*/
|
||||
String HEADER = "accessToken";
|
||||
|
||||
String ATTRIBUTE_APP_USER = "ATTRIBUTE_APP_USER";
|
||||
|
||||
/**
|
||||
* 权限参数头
|
||||
*/
|
||||
|
||||
@@ -1,8 +1,13 @@
|
||||
package com.sunyard.chsm.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.sunyard.chsm.model.entity.CryptoServiceApi;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author liulu
|
||||
@@ -10,4 +15,17 @@ import org.apache.ibatis.annotations.Mapper;
|
||||
*/
|
||||
@Mapper
|
||||
public interface CryptoServiceApiMapper extends BaseMapper<CryptoServiceApi> {
|
||||
|
||||
default List<CryptoServiceApi> selectByServiceIds(List<Long> serviceIds) {
|
||||
if (CollectionUtils.isEmpty(serviceIds)) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return selectList(
|
||||
new LambdaQueryWrapper<CryptoServiceApi>()
|
||||
.in(CryptoServiceApi::getCryptoServiceId, serviceIds)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user