diff --git a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/family/FamilyMemberTop100Exe.java b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/family/FamilyMemberTop100Exe.java index b3e9f82a..721c6d2d 100644 --- a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/family/FamilyMemberTop100Exe.java +++ b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/family/FamilyMemberTop100Exe.java @@ -45,7 +45,21 @@ public class FamilyMemberTop100Exe { List top200Exp = getTop200TotalExp(member.getFamilyId()); if (CollectionUtils.isEmpty(top200Exp)) { - return new FamilyLeaderboardCO(); + FamilyLeaderboardCO leaderboardCO = new FamilyLeaderboardCO(); + + Map userProfileMap = userProfileGateway.mapByUserIds(Set.of(cmd.getReqUserId())); + Set hostUserIds = getHostUserIds(Set.of(cmd.getReqUserId())); + FamilyMemberRankInfoCO myRankInfo = buildMyRankInfo( + cmd.getReqUserId(), + new FamilyMemberTotalExp().setExp(0L), + userProfileMap.get(cmd.getReqUserId()), + 0, + 0, + hostUserIds.contains(cmd.getReqUserId()) + ); + + leaderboardCO.setMyRankInfo(myRankInfo); + return leaderboardCO; } Set userIds = top200Exp.stream() @@ -150,9 +164,9 @@ public class FamilyMemberTop100Exe { ) { String rank; if (isHost) { - rank = myRankInHost > 0 ? (myRankInHost > 100 ? "100+" : String.valueOf(myRankInHost)) : "100+"; + rank = myRankInHost > 0 ? (myRankInHost > 100 ? "100+" : String.valueOf(myRankInHost)) : "0"; } else { - rank = myRankInSupporter > 0 ? (myRankInSupporter > 100 ? "100+" : String.valueOf(myRankInSupporter)) : "100+"; + rank = myRankInSupporter > 0 ? (myRankInSupporter > 100 ? "100+" : String.valueOf(myRankInSupporter)) : "0"; } return new FamilyMemberRankInfoCO()