【update】null值处理
This commit is contained in:
parent
7db999404b
commit
d83f96c601
|
@ -10,6 +10,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 基础方法工具类
|
||||
|
@ -28,7 +29,7 @@ public class BaseUtil {
|
|||
}
|
||||
|
||||
public List<Long> getRouteIds(){
|
||||
List<String> list = BaseContext.getCurrentUser().loadRoleOrg().getRoleOrgCodeList();
|
||||
List<String> list = BaseContext.getCurrentUser().loadRoleOrg().getRoleOrgCodeList().stream().filter(Objects::nonNull).toList();
|
||||
List<RouteOrderExtensionFieldBasic> result= jdbcRouteOrderExtensionFieldBasicRepository.findAllByBelongDeptCodeIn(list);
|
||||
return result.stream().map(RouteOrderExtensionFieldBasic::getRouteId).toList();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue