Browse Source

活动详情页- 活动当前状态修改

dev_shibei_match
zhangyongzhangyong 5 years ago
parent
commit
3462a19f48
  1. 14
      epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/ActInfoServiceImpl.java

14
epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/ActInfoServiceImpl.java

@ -23,6 +23,7 @@ import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.constant.FieldConstant;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.exception.EpmetErrorCode;
import com.epmet.commons.tools.exception.RenException;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.ConvertUtils;
@ -297,13 +298,12 @@ public class ActInfoServiceImpl extends BaseServiceImpl<ActInfoDao, ActInfoEntit
} else if (currentTime.after(actInfoEntity.getSignUpEndTime()) && currentTime.before(actInfoEntity.getActStartTime())) {
/*报名结束,活动未开始:显示:截止报名*/
return ActConstant.CURRENT_STATUS_USER_END_SIGN_UP;
} else if (currentTime.after(actInfoEntity.getActStartTime()) && currentTime.before(actInfoEntity.getActEndTime())) {
// 活动开始-结束的时间段内: 显示:已开始
} else if (currentTime.after(actInfoEntity.getActStartTime())) {
// 活动开始以后: 显示:已开始
return ActConstant.CURRENT_STATUS_USER_IN_PROGRESS;
} else {
// 最后,显示:已结束
return ActConstant.CURRENT_STATUS_USER_FINISHED;
}
// 活动的状态是:finished ,显示:已结束
return ActConstant.CURRENT_STATUS_USER_FINISHED;
}
/**
@ -326,8 +326,8 @@ public class ActInfoServiceImpl extends BaseServiceImpl<ActInfoDao, ActInfoEntit
return ActConstant.CURRENT_STATUS_USER_POINTS_CONFIRM;
}
if (currentTime.after(actInfoEntity.getActStartTime()) && currentTime.before(actInfoEntity.getActEndTime())) {
/* 活动开始-结束的时间段内 */
if (currentTime.after(actInfoEntity.getActStartTime())) {
/* 活动开始 */
return ActConstant.CURRENT_STATUS_USER_IN_PROGRESS;
} else if (currentTime.before(actInfoEntity.getSignUpEndTime())) {
/* 报名截至时间前 */

Loading…
Cancel
Save