| | |
| | | import com.yeshi.fanli.util.Constant;
|
| | | import com.yeshi.fanli.util.JumpDetailUtil;
|
| | | import com.yeshi.fanli.util.jd.JDApiUtil;
|
| | | import com.yeshi.fanli.vo.homemodule.SpecialVO;
|
| | | import com.yeshi.fanli.vo.msg.ClientTextStyleVO;
|
| | |
|
| | | import net.sf.json.JSONObject;
|
| | |
| | | listKey.add("special_channel_jd");
|
| | | listKey.add("special_channel_pdd");
|
| | |
|
| | | List<Special> list = specialService.listByPlaceKeyHasLabel((page - 1) * Constant.PAGE_SIZE, Constant.PAGE_SIZE,
|
| | | List<SpecialVO> list = specialService.listByPlaceKeyHasLabel((page - 1) * Constant.PAGE_SIZE, Constant.PAGE_SIZE,
|
| | | listKey, platformCode, Integer.parseInt(acceptData.getVersion()));
|
| | |
|
| | | long time = System.currentTimeMillis();
|
| | |
|
| | | // 删除尚未启用的过期的
|
| | | for (int i = 0; i < list.size(); i++) {
|
| | | Special special = list.get(i);
|
| | | SpecialVO special = list.get(i);
|
| | | if (special.getJumpDetail() != null) {
|
| | | special.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(special.getJumpDetail()));
|
| | | }
|
| | |
| | | if (special.getState() == 1L) {
|
| | | list.remove(i--);
|
| | | } else {
|
| | | if (special.getStartTime() != null && special.getEndTime() != null)
|
| | | special.setTimeTask(true);
|
| | | else
|
| | | special.setTimeTask(false);
|
| | |
|
| | | if (special.isTimeTask()) {
|
| | | if (special.getStartTime() != null && special.getEndTime() != null) {
|
| | | if (time < special.getStartTime().getTime() || time > special.getEndTime().getTime()) {
|
| | | list.remove(i--);
|
| | | } else// 设置倒计时
|