Commit 1a0ca895 authored by 许润龙's avatar 许润龙

修改:活动视频、直播数据详情数据接口

parent d8912115
......@@ -6,6 +6,7 @@ import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.StrUtil;
import com.afanticar.afantiopenapi.model.BaseResponse;
import com.afanticar.afantiopenapi.model.dto.FawActivityDTO;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.web.context.request.RequestContextHolder;
import org.springframework.web.context.request.ServletRequestAttributes;
......@@ -103,6 +104,9 @@ public class BaseController {
if (DateUtil.between(publishDateEnd, publishDateStart, DateUnit.DAY) > dateNum) {
return BaseController.error("10010", "时间跨度最大为31天!");
}
if (CollectionUtils.isEmpty(dto.getActivityIds()) || dto.getActivityIds().size() > 5) {
return BaseController.error("10010", "活动ID不能为空,最大5个!");
}
dto.setEnd(publishDateEnd);
dto.setStart(publishDateStart);
dto.setCurrent(dto.getCurrent() == null ? 1 : dto.getCurrent());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment