| | |
| | | // 图文详情
|
| | | extraVO.setDetailUrl("http://apph5.yeshitv.com/apppage/goods_img_pdd.html?id="+ id);
|
| | |
|
| | | Long inOrderCount30Days = pddGoods.getSoldQuantity();
|
| | | List<ShamUser> listShareUser = new ArrayList<ShamUser>();
|
| | | MoneyInfoVO moneyInfo = goodsDetail.getMoneyInfo();
|
| | | if (moneyInfo != null) {
|
| | | String shareMoney = moneyInfo.getShareMoney().replaceAll("¥", "");
|
| | | if (Integer.parseInt(inOrderCount30Days.toString()) >= 50000) {
|
| | | listShareUser = shamUserService.listRandShareUser(10, new BigDecimal(shareMoney), 1, 5);
|
| | | String salesTip = pddGoods.getSalesTip();
|
| | | if (!StringUtil.isNullOrEmpty(salesTip)) {
|
| | | int totalSales = 0;
|
| | | if (salesTip.contains("万")) {
|
| | | salesTip = salesTip.substring(0, salesTip.indexOf("万"));
|
| | | totalSales= (int) (Float.parseFloat(salesTip) * 10000);
|
| | | } else {
|
| | | totalSales = Integer.parseInt(salesTip);
|
| | | }
|
| | | }
|
| | | extraVO.setListShareUser(listShareUser);
|
| | | |
| | | List<ShamUser> listShareUser = new ArrayList<ShamUser>();
|
| | | MoneyInfoVO moneyInfo = goodsDetail.getMoneyInfo();
|
| | | if (moneyInfo != null) {
|
| | | String shareMoney = moneyInfo.getShareMoney().replaceAll("¥", "");
|
| | | if (totalSales >= 50000) {
|
| | | listShareUser = shamUserService.listRandShareUser(10, new BigDecimal(shareMoney), 1, 5);
|
| | | }
|
| | | }
|
| | | extraVO.setListShareUser(listShareUser);
|
| | |
|
| | | // 领券人列表
|
| | | List<ShamUser> listCouponUser = new ArrayList<ShamUser>();
|
| | | if (goodsDetail.isHasCoupon() && Integer.parseInt(inOrderCount30Days.toString()) >= 50000) {
|
| | | listCouponUser = shamUserService.listRandCouponUser(5, 1, 300);
|
| | | // 领券人列表
|
| | | List<ShamUser> listCouponUser = new ArrayList<ShamUser>();
|
| | | if (goodsDetail.isHasCoupon() && totalSales >= 50000) {
|
| | | listCouponUser = shamUserService.listRandCouponUser(5, 1, 300);
|
| | | }
|
| | | extraVO.setListCouponUser(listCouponUser);
|
| | | }
|
| | | extraVO.setListCouponUser(listCouponUser);
|
| | |
|
| | | |
| | | if (uid != null) {
|
| | | // 是否加入收藏
|
| | | CollectionGoodsV2 collectionGoods = collectionGoodsV2Service.findByUidAndAuctionId(uid, id,
|
| | |
| | | // 京东
|
| | | if (goodsType == Constant.SOURCE_TYPE_JD) {
|
| | | JSONObject data = new JSONObject();
|
| | | data.put("listQuality", JsonUtil.getApiCommonGson().toJson(new ArrayList<GoodsDetailVO>()));
|
| | | data.put("listGuess", JsonUtil.getApiCommonGson().toJson(new ArrayList<GoodsDetailVO>()));
|
| | |
|
| | | List<JDGoods> list = JDUtil.getRecommendGoodsById(id);
|
| | | if (list == null) {
|
| | |
| | | listDetailVO.remove(listDetailVO.size() - 1);
|
| | | }
|
| | |
|
| | | data.put("listGuess", JsonUtil.getApiCommonGson().toJson(listDetailVO));
|
| | | data.put("listQuality", JsonUtil.getApiCommonGson().toJson(listDetailVO));
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | return;
|
| | | }
|
| | |
| | | // 拼多多
|
| | | if (goodsType == Constant.SOURCE_TYPE_PDD) {
|
| | | JSONObject data = new JSONObject();
|
| | | data.put("listQuality", JsonUtil.getApiCommonGson().toJson(new ArrayList<GoodsDetailVO>()));
|
| | | data.put("listGuess", JsonUtil.getApiCommonGson().toJson(new ArrayList<GoodsDetailVO>()));
|
| | |
|
| | | List<GoodsDetailVO> listDetailVO = new ArrayList<GoodsDetailVO>();
|
| | |
|
| | |
| | | listDetailVO.remove(listDetailVO.size() - 1);
|
| | | }
|
| | |
|
| | | data.put("listGuess", JsonUtil.getApiCommonGson().toJson(listDetailVO));
|
| | | data.put("listQuality", JsonUtil.getApiCommonGson().toJson(listDetailVO));
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | return;
|
| | | }
|