| | |
| | | if (addComment) { |
| | | String commentText = ""; |
| | | if (goodsType == Constant.SOURCE_TYPE_TAOBAO) { |
| | | TaoBaoLink taoBaoLink = shareGoodsService.getTaoBaoLinkForShare(0L, goodsId, null); |
| | | TaoBaoLink taoBaoLink = shareGoodsService.getTaoBaoLinkForShare(1L, goodsId, null); |
| | | String template = configService.get(ConfigKeyEnum.quickShareTBCommentText.getKey()); |
| | | commentText = template.replace("[口令]", TaoBaoUtil.filterTaoToken(taoBaoLink.getTaoToken())); |
| | | } else if (goodsType == Constant.SOURCE_TYPE_JD) { |
| | |
| | | couponUrl = couponInfo.getLink(); |
| | | } |
| | | String materialId = "https://item.jd.com/" + goodsId + ".html"; |
| | | String jumpLink = JDApiUtil.convertLinkWithSubUnionId(materialId, couponUrl, JDApiUtil.POSITION_SHARE + "","0"); |
| | | String jumpLink = JDApiUtil.convertLinkWithSubUnionId(materialId, couponUrl, JDApiUtil.POSITION_SHARE + "","1"); |
| | | String template = configService.get(ConfigKeyEnum.quickShareJDCommentText.getKey()); |
| | | commentText = template.replace("[链接]", jumpLink); |
| | | } else if (goodsType == Constant.SOURCE_TYPE_PDD) { |
| | | String jumpLink = PinDuoDuoApiUtil.getPromotionUrl(goodsId, PinDuoDuoApiUtil.PID_SHARE + "", "0"); |
| | | String jumpLink = PinDuoDuoApiUtil.getPromotionUrl(goodsId, PinDuoDuoApiUtil.PID_SHARE + "", "1"); |
| | | String template = configService.get(ConfigKeyEnum.quickSharePDDCommentText.getKey()); |
| | | commentText = template.replace("[链接]", jumpLink); |
| | | } |