|
|
@@ -109,7 +109,7 @@ public class ExpertInviteTask { |
|
|
|
return; |
|
|
|
} |
|
|
|
for (InviteCacheDTO cache : caches.values()) { |
|
|
|
addInviteExpertTask(cache.getMeetingId(), true, properties.getInviteDelay(), cache.getInvitedRefused()); |
|
|
|
addInviteTask(cache.getMeetingId(), true, properties.getInviteDelay(), cache.getInvitedRefused()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
@@ -156,7 +156,7 @@ public class ExpertInviteTask { |
|
|
|
tmpInvitedRefused = invitedRefused[0]; |
|
|
|
} |
|
|
|
if (!INVITE_MAP.containsKey(meetingId)) { |
|
|
|
addInviteExpertTask(meetingId, false, properties.getInviteDelay(), tmpInvitedRefused); |
|
|
|
addInviteTask(meetingId, false, properties.getInviteDelay(), tmpInvitedRefused); |
|
|
|
log.info("重置会议的随机抽取状态:{}", meetingId); |
|
|
|
LambdaUpdateWrapper<Meeting> update = Wrappers.lambdaUpdate(Meeting.class); |
|
|
|
update.set(Meeting::getInviteStatus, false); |
|
|
@@ -176,7 +176,7 @@ public class ExpertInviteTask { |
|
|
|
* @param invitedRefused 是否可以邀请被拒绝的专家 |
|
|
|
* @author WendyYang |
|
|
|
**/ |
|
|
|
public void addInviteExpertTask(Long meetingId, boolean checked, int delayedMinutes, boolean invitedRefused) { |
|
|
|
public void addInviteTask(Long meetingId, boolean checked, int delayedMinutes, boolean invitedRefused) { |
|
|
|
if (checked && !inviteCountCheck(meetingId)) { |
|
|
|
// 如果抽取数量满足直接返回 |
|
|
|
return; |
|
|
@@ -201,9 +201,9 @@ public class ExpertInviteTask { |
|
|
|
* @param delayedMinutes 延迟时间 |
|
|
|
* @author WendyYang |
|
|
|
**/ |
|
|
|
public void addInviteExpertTaskByMeetingCreate(Long meetingId, int delayedMinutes) { |
|
|
|
public void addInviteTaskByMeetingCreate(Long meetingId, int delayedMinutes) { |
|
|
|
Assert.isTrue(properties.getEnable(), "随机邀请已关闭"); |
|
|
|
addInviteExpertTask(meetingId, false, delayedMinutes, false); |
|
|
|
addInviteTask(meetingId, false, delayedMinutes, false); |
|
|
|
InviteCacheDTO cacheVal = InviteCacheDTO.of(meetingId, false); |
|
|
|
cachePlusOps.hSet(getCacheKey(meetingId), cacheVal); |
|
|
|
} |
|
|
|