| | |
| | | import com.yeshi.fanli.dto.pdd.PDDGoodsDetail;
|
| | | import com.yeshi.fanli.dto.pdd.PDDGoodsResult;
|
| | | import com.yeshi.fanli.entity.accept.AcceptData;
|
| | | import com.yeshi.fanli.entity.bus.homemodule.Special;
|
| | | import com.yeshi.fanli.entity.bus.homemodule.SwiperPicture;
|
| | | import com.yeshi.fanli.entity.common.JumpDetailV2;
|
| | | import com.yeshi.fanli.entity.jd.JDGoods;
|
| | | import com.yeshi.fanli.entity.system.ConfigKeyEnum;
|
| | |
| | | import com.yeshi.fanli.service.inter.lable.QualityFlashSaleService;
|
| | | import com.yeshi.fanli.service.inter.lable.QualityGoodsService;
|
| | | import com.yeshi.fanli.service.inter.monitor.MonitorService;
|
| | | import com.yeshi.fanli.service.inter.order.OrderHongBaoMoneyComputeService;
|
| | | import com.yeshi.fanli.service.inter.order.config.HongBaoManageService;
|
| | | import com.yeshi.fanli.service.inter.pdd.PDDGoodsService;
|
| | | import com.yeshi.fanli.service.inter.taobao.TaoBaoGoodsUpdateService;
|
| | |
| | | import com.yeshi.fanli.util.StringUtil;
|
| | | import com.yeshi.fanli.util.factory.goods.GoodsDetailVOFactory;
|
| | | import com.yeshi.fanli.vo.goods.GoodsDetailVO;
|
| | | import com.yeshi.fanli.vo.homemodule.BannerVO;
|
| | | import com.yeshi.fanli.vo.homemodule.SpecialVO;
|
| | |
|
| | | import net.sf.json.JSONArray;
|
| | | import net.sf.json.JSONObject;
|
| | |
| | |
|
| | | @Resource
|
| | | private HongBaoManageService hongBaoManageService;
|
| | | |
| | | @Resource
|
| | | private OrderHongBaoMoneyComputeService orderHongBaoMoneyComputeService;
|
| | |
|
| | | @Resource
|
| | | private QualityGoodsService qualityGoodsService;
|
| | |
| | | int version = Integer.parseInt(acceptData.getVersion());
|
| | |
|
| | | // 轮播图
|
| | | List<SwiperPicture> picList = swiperPictureService.getByBannerCardAndVersion("index_top", platform,
|
| | | List<BannerVO> picList = swiperPictureService.getByBannerCardAndVersion("index_top", platform,
|
| | | version);
|
| | | if (picList == null) {
|
| | | picList = new ArrayList<>();
|
| | | }
|
| | |
|
| | | for (SwiperPicture swiper : picList) {
|
| | | JSONObject params = null;
|
| | | if (StringUtil.isNullOrEmpty(swiper.getParams())) {
|
| | | params = JSONObject.fromObject(swiper.getParams());
|
| | | }
|
| | | swiper.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(swiper.getJumpDetail(), params));
|
| | | swiper.setParams(null);
|
| | | for (BannerVO swiper : picList) {
|
| | | // JSONObject params = null;
|
| | | // if (StringUtil.isNullOrEmpty(swiper.getParams())) {
|
| | | // params = JSONObject.fromObject(swiper.getParams());
|
| | | // }
|
| | | swiper.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(swiper.getJumpDetail()));
|
| | | }
|
| | |
|
| | | // 圆形专题
|
| | | List<Special> specials = specialService.listByVersion(0, 10, "index_arc_1.6.5", platform, version);
|
| | | List<SpecialVO> specials = specialService.listByVersion(0, 10, "index_arc_1.6.5", platform, version);
|
| | | if (specials == null)
|
| | | specials = new ArrayList<>();
|
| | |
|
| | | for (Special special : specials) {
|
| | | for (SpecialVO special : specials) {
|
| | | JumpDetailV2 jumpDetail = special.getJumpDetail();
|
| | | if (special.isJumpLogin() && jumpDetail != null) {
|
| | | jumpDetail.setNeedLogin(true);
|
| | | }
|
| | |
|
| | | JSONObject params = null;
|
| | | if (StringUtil.isNullOrEmpty(special.getParams())) {
|
| | | params = JSONObject.fromObject(special.getParams());
|
| | | }
|
| | | |
| | | special.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(jumpDetail, params));
|
| | | special.setParams(null);
|
| | | // JSONObject params = null;
|
| | | // if (StringUtil.isNullOrEmpty(special.getParams())) {
|
| | | // params = JSONObject.fromObject(special.getParams());
|
| | | // }
|
| | | special.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(jumpDetail));
|
| | | }
|
| | |
|
| | | // 活动
|
| | | List<SwiperPicture> activitys = swiperPictureService.getByBannerCardAndVersion("index_invite", platform,
|
| | | List<BannerVO> activitys = swiperPictureService.getByBannerCardAndVersion("index_invite", platform,
|
| | | version);
|
| | | if (activitys == null)
|
| | | activitys = new ArrayList<>();
|
| | |
|
| | | for (SwiperPicture swiper : activitys) {
|
| | | JSONObject params = null;
|
| | | if (StringUtil.isNullOrEmpty(swiper.getParams())) {
|
| | | params = JSONObject.fromObject(swiper.getParams());
|
| | | }
|
| | | swiper.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(swiper.getJumpDetail(), params));
|
| | | swiper.setParams(null);
|
| | | for (BannerVO swiper : activitys) {
|
| | | // JSONObject params = null;
|
| | | // if (StringUtil.isNullOrEmpty(swiper.getParams())) {
|
| | | // params = JSONObject.fromObject(swiper.getParams());
|
| | | // }
|
| | | swiper.setJumpDetail(JumpDetailUtil.getWXMPJumDetail(swiper.getJumpDetail()));
|
| | | }
|
| | |
|
| | | JSONObject data = new JSONObject();
|
| | |
| | | JSONObject data = new JSONObject();
|
| | | data.put("list", new JSONArray());
|
| | | data.put("count", 0);
|
| | | data.put("page", page);
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | }
|
| | | }
|
| | |
| | |
|
| | | List<JDGoods> goodsList = result.getGoodsList();
|
| | | if (goodsList != null && goodsList.size() > 0) {
|
| | | ConfigParamsDTO paramsDTO = hongBaoManageService.getShowComputeRate(acceptData.getPlatform(),
|
| | | ConfigParamsDTO paramsDTO = orderHongBaoMoneyComputeService.getShowComputeRate(acceptData.getPlatform(),
|
| | | acceptData.getVersion());
|
| | |
|
| | | Gson gson = JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder())
|
| | |
| | |
|
| | | data.put("list", array);
|
| | | data.put("count", count);
|
| | | data.put("page", page);
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | }
|
| | |
|
| | |
| | | Gson gson = JsonUtil.getApiCommonGson();
|
| | | List<PDDGoodsDetail> goodsList = result.getGoodsList();
|
| | | if (goodsList != null && goodsList.size() > 0) {
|
| | | ConfigParamsDTO paramsDTO = hongBaoManageService.getShowComputeRate(acceptData.getPlatform(),
|
| | | ConfigParamsDTO paramsDTO = orderHongBaoMoneyComputeService.getShowComputeRate(acceptData.getPlatform(),
|
| | | acceptData.getVersion());
|
| | |
|
| | | for (PDDGoodsDetail goods : goodsList) {
|
| | |
| | | JSONObject data = new JSONObject();
|
| | | data.put("list", array);
|
| | | data.put("count", count);
|
| | | data.put("page", page);
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | }
|
| | |
|