| | |
| | | |
| | | if (shareHistory != null) {// 有分享记录 |
| | | token = shareHistory.getTkCode(); |
| | | goods = redisManager.getTaoBaoGoodsTemp(Long.parseLong(id)); |
| | | goods = redisManager.getTaoBaoGoodsTemp(id); |
| | | if (goods == null) |
| | | try { |
| | | goods = TaoKeApiUtil.searchGoodsDetail(id); |
| | |
| | | url = goods.getCouponLink(); |
| | | } |
| | | if (!url.contains("uland.taobao.com") && !url.contains("s.click.taobao.com")) { |
| | | TaoBaoGoodsBrief linkInfo = TaoKeApiUtil.specialConvertCoupon(id, app, null, null); |
| | | TaoBaoGoodsBrief linkInfo = TaoKeApiUtil.specialConvertCouponV2(id, app, null, null); |
| | | url = linkInfo.getCouponLink(); |
| | | if (StringUtil.isNullOrEmpty(url)) |
| | | url = linkInfo.getAuctionUrl(); |
| | |
| | | public void run() { |
| | | try { |
| | | if (!StringUtil.isNullOrEmpty(tempUid)) |
| | | userShareGoodsGroupService.updateBrowseRecord(Long.parseLong(tempUid), Long.parseLong(id), 1); |
| | | userShareGoodsGroupService.updateBrowseRecord(Long.parseLong(tempUid), id, 1); |
| | | } catch (NumberFormatException e) { |
| | | e.printStackTrace(); |
| | | } catch (UserShareGoodsRecordException e) { |
| | |
| | | * @param out |
| | | */ |
| | | @RequestMapping(value = "getJDGoodsDetail") |
| | | public void getJDGoodsDetail(final AcceptData acceptData, final Long id, String uid, String callback, |
| | | public void getJDGoodsDetail(final AcceptData acceptData, final String id, String uid, String callback, |
| | | PrintWriter out) { |
| | | if (id == null) { |
| | | out.print(JsonUtil.loadFalseResult(1, "请上传id")); |
| | |
| | | |
| | | int priceType = 1; |
| | | BigDecimal price = jdGoods.getPrice(); |
| | | ; |
| | | JDPingouInfo pinGouInfo = jdGoods.getPinGouInfo(); |
| | | if (pinGouInfo != null) { |
| | | priceType = 2; // 拼购价 |
| | |
| | | public void run() { |
| | | try { |
| | | if (!StringUtil.isNullOrEmpty(tempUid)) |
| | | userShareGoodsGroupService.updateBrowseNum(Long.parseLong(tempUid), id, |
| | | userShareGoodsGroupService.updateBrowseNum(Long.parseLong(tempUid), id+"", |
| | | Constant.SOURCE_TYPE_JD); |
| | | } catch (NumberFormatException e) { |
| | | e.printStackTrace(); |
| | |
| | | * @param out |
| | | */ |
| | | @RequestMapping(value = "getPDDGoodsDetail") |
| | | public void getPDDGoodsDetail(final AcceptData acceptData, final Long id, String uid, String callback, |
| | | public void getPDDGoodsDetail(final AcceptData acceptData, final String id, String uid, String callback, |
| | | PrintWriter out) { |
| | | if (id == null) { |
| | | out.print(JsonUtil.loadFalseResult(1, "请上传id")); |
| | |
| | | public void run() { |
| | | try { |
| | | if (!StringUtil.isNullOrEmpty(tempUid)) |
| | | userShareGoodsGroupService.updateBrowseNum(Long.parseLong(tempUid), id, |
| | | userShareGoodsGroupService.updateBrowseNum(Long.parseLong(tempUid), id+"", |
| | | Constant.SOURCE_TYPE_PDD); |
| | | } catch (NumberFormatException e) { |
| | | e.printStackTrace(); |