Commit 798e374b by zhangxingmin

push

parent ed708858
...@@ -255,7 +255,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService { ...@@ -255,7 +255,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService {
.eq(AgentManageRelation::getAgentId, clientUserBizId) .eq(AgentManageRelation::getAgentId, clientUserBizId)
.list() // 可能包含 null 元素 .list() // 可能包含 null 元素
.stream() .stream()
.filter(Objects::nonNull) // 关键:过滤掉 null 对象 .filter(Objects::nonNull) // 过滤掉 null 对象
.map(AgentManageRelation::getManageId) .map(AgentManageRelation::getManageId)
.collect(Collectors.toList()); .collect(Collectors.toList());
log.info("获取一级管理列表=>manageIdList:{}", JSON.toJSONString(manageIdList)); log.info("获取一级管理列表=>manageIdList:{}", JSON.toJSONString(manageIdList));
...@@ -292,6 +292,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService { ...@@ -292,6 +292,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService {
.eq(AgentManageRelation::getAgentId, clientUserBizId) .eq(AgentManageRelation::getAgentId, clientUserBizId)
.list() // 返回 List<AgentTutoringRelation> .list() // 返回 List<AgentTutoringRelation>
.stream() .stream()
.filter(Objects::nonNull)
.map(AgentManageRelation::getSManageId) .map(AgentManageRelation::getSManageId)
.collect(Collectors.toList()); .collect(Collectors.toList());
if (CollectionUtils.isEmpty(manageIdList)) { if (CollectionUtils.isEmpty(manageIdList)) {
...@@ -327,6 +328,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService { ...@@ -327,6 +328,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService {
.eq(AgentReferralRelation::getAgentId, clientUserBizId) .eq(AgentReferralRelation::getAgentId, clientUserBizId)
.list() // 返回 List<AgentTutoringRelation> .list() // 返回 List<AgentTutoringRelation>
.stream() .stream()
.filter(Objects::nonNull)
.map(AgentReferralRelation::getReferrerId) .map(AgentReferralRelation::getReferrerId)
.collect(Collectors.toList()); .collect(Collectors.toList());
if (CollectionUtils.isEmpty(referrerIdList)) { if (CollectionUtils.isEmpty(referrerIdList)) {
...@@ -362,6 +364,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService { ...@@ -362,6 +364,7 @@ public class ApiCsfClientUserServiceImpl implements ApiCsfClientUserService {
.eq(AgentTutoringRelation::getAgentId, clientUserBizId) .eq(AgentTutoringRelation::getAgentId, clientUserBizId)
.list() // 返回 List<AgentTutoringRelation> .list() // 返回 List<AgentTutoringRelation>
.stream() .stream()
.filter(Objects::nonNull)
.map(AgentTutoringRelation::getTutorId) .map(AgentTutoringRelation::getTutorId)
.collect(Collectors.toList()); .collect(Collectors.toList());
if (CollectionUtils.isEmpty(tutorIdList)) { if (CollectionUtils.isEmpty(tutorIdList)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment