|
@@ -372,7 +372,7 @@ public class ExpertInviteManage { |
|
|
AvoidTypeEnum avoidType = avoidRule.getAvoidType() == null ? AvoidTypeEnum.CURR_UNIT : AvoidTypeEnum.getByCode(avoidRule.getAvoidType()); |
|
|
AvoidTypeEnum avoidType = avoidRule.getAvoidType() == null ? AvoidTypeEnum.CURR_UNIT : AvoidTypeEnum.getByCode(avoidRule.getAvoidType()); |
|
|
switch (avoidType) { |
|
|
switch (avoidType) { |
|
|
case NONE: |
|
|
case NONE: |
|
|
result.setExperts(inviteWithoutCompany(userInfoList, expertsByRecentMeeting(), randomRule.getCount())); |
|
|
|
|
|
|
|
|
result.setExperts(inviteRandom(userInfoList, expertsByRecentMeeting(), randomRule.getCount())); |
|
|
result.setTotal(userInfoList.size()); |
|
|
result.setTotal(userInfoList.size()); |
|
|
break; |
|
|
break; |
|
|
case CURR_UNIT: |
|
|
case CURR_UNIT: |
|
@@ -475,12 +475,12 @@ public class ExpertInviteManage { |
|
|
expertIdsNotIn.addAll(agreeOrNoticingExpertIds); |
|
|
expertIdsNotIn.addAll(agreeOrNoticingExpertIds); |
|
|
if (AvoidTypeEnum.CURR_UNIT.equals(avoidType)) { |
|
|
if (AvoidTypeEnum.CURR_UNIT.equals(avoidType)) { |
|
|
List<ExpertUserFullInfo> agreeOrNoticingUserInfos = expertUserFullInfoService.listByUserIds(agreeOrNoticingExpertIds); |
|
|
List<ExpertUserFullInfo> agreeOrNoticingUserInfos = expertUserFullInfoService.listByUserIds(agreeOrNoticingExpertIds); |
|
|
List<String> tmpUniqCompanyCodes = CollUtils.fieldList(agreeOrNoticingUserInfos, ExpertUserFullInfo::getCompanyUniqCode); |
|
|
|
|
|
|
|
|
Set<String> tmpUniqCompanyCodes = CollUtils.fieldSet(agreeOrNoticingUserInfos, ExpertUserFullInfo::getCompanyUniqCode); |
|
|
notInCompanyUniqCodeList.addAll(tmpUniqCompanyCodes); |
|
|
notInCompanyUniqCodeList.addAll(tmpUniqCompanyCodes); |
|
|
} else if (AvoidTypeEnum.CURR_STRIP.equals(avoidType)) { |
|
|
} else if (AvoidTypeEnum.CURR_STRIP.equals(avoidType)) { |
|
|
List<ExpertGovBusinessStrip> expertStrips = expertGovBusinessStripService.listByUserIds(agreeOrNoticingExpertIds); |
|
|
List<ExpertGovBusinessStrip> expertStrips = expertGovBusinessStripService.listByUserIds(agreeOrNoticingExpertIds); |
|
|
if (CollUtil.isNotEmpty(expertStrips)) { |
|
|
if (CollUtil.isNotEmpty(expertStrips)) { |
|
|
List<String> businessStripCodes = CollUtils.fieldList(expertStrips, ExpertGovBusinessStrip::getBusinessStripCode); |
|
|
|
|
|
|
|
|
Set<String> businessStripCodes = CollUtils.fieldSet(expertStrips, ExpertGovBusinessStrip::getBusinessStripCode); |
|
|
query.notExists("select 1 from expert_gov_business_strip egbs " + |
|
|
query.notExists("select 1 from expert_gov_business_strip egbs " + |
|
|
"where egbs.expertUserId = nd_expert_user_full_info.user_id " + |
|
|
"where egbs.expertUserId = nd_expert_user_full_info.user_id " + |
|
|
"and egbs.business_strip_code in " + BizUtils.inSqlJoin(businessStripCodes)); |
|
|
"and egbs.business_strip_code in " + BizUtils.inSqlJoin(businessStripCodes)); |
|
@@ -526,7 +526,7 @@ public class ExpertInviteManage { |
|
|
} |
|
|
} |
|
|
switch (avoidType) { |
|
|
switch (avoidType) { |
|
|
case NONE: |
|
|
case NONE: |
|
|
result.setExperts(inviteWithoutCompany(userFullInfos, expertsByRecentMeeting(), count)); |
|
|
|
|
|
|
|
|
result.setExperts(inviteRandom(userFullInfos, expertsByRecentMeeting(), count)); |
|
|
result.setTotal(userFullInfos.size()); |
|
|
result.setTotal(userFullInfos.size()); |
|
|
break; |
|
|
break; |
|
|
case CURR_UNIT: |
|
|
case CURR_UNIT: |
|
|