diff --git a/luoo_common/src/main/java/constants/ErrorConstants.java b/luoo_common/src/main/java/constants/ErrorConstants.java index 6001b96..769629d 100644 --- a/luoo_common/src/main/java/constants/ErrorConstants.java +++ b/luoo_common/src/main/java/constants/ErrorConstants.java @@ -61,6 +61,6 @@ public class ErrorConstants { public static final String POINT_NOT_ENOUGH = "积分不足"; // 积分部分 - public static final String DAILY_SIGN_ALREADY = "进入已签到"; + public static final String DAILY_SIGN_ALREADY = "今日已签到"; } diff --git a/luoo_user/src/main/java/com/luoo/user/service/TaskPointService.java b/luoo_user/src/main/java/com/luoo/user/service/TaskPointService.java index e4b4fa6..7524002 100644 --- a/luoo_user/src/main/java/com/luoo/user/service/TaskPointService.java +++ b/luoo_user/src/main/java/com/luoo/user/service/TaskPointService.java @@ -193,14 +193,15 @@ public class TaskPointService { } else { taskPoint.setUserStatus(PointEnums.NOT_PARTICIPATED.getCode()); } - } - if (Objects.equals(taskPoint.getType(), Integer.valueOf(TaskPointIdConstants.DAILY_SIGN))) { - // 校验今日是否已签到 - UserPointLog todayByUserIdAndTaskPointId = userPointLogDao.findTodayByUserIdAndTaskPointId(userLoginDto.getUserId(), TaskPointIdConstants.DAILY_SIGN); - if(todayByUserIdAndTaskPointId != null) { - taskPoint.setUserStatus(PointEnums.PARTICIPATED.getCode()); - } else { - taskPoint.setUserStatus(PointEnums.NOT_PARTICIPATED.getCode()); + } else { + if (!Objects.equals(taskPoint.getId(), TaskPointIdConstants.NEW_USER_INVITE)) { + // 校验今日是否已签到 + UserPointLog todayByUserIdAndTaskPointId = userPointLogDao.findTodayByUserIdAndTaskPointId(userLoginDto.getUserId(), taskPoint.getId()); + if(todayByUserIdAndTaskPointId != null) { + taskPoint.setUserStatus(PointEnums.PARTICIPATED.getCode()); + } else { + taskPoint.setUserStatus(PointEnums.NOT_PARTICIPATED.getCode()); + } } }