fanli/src/main/java/com/yeshi/fanli/controller/client/v2/DynamicControllerV2.java
@@ -34,6 +34,7 @@ import com.yeshi.fanli.entity.bus.user.UserInfo; import com.yeshi.fanli.entity.common.JumpDetailV2; import com.yeshi.fanli.entity.dynamic.CommentInfo; import com.yeshi.fanli.entity.dynamic.CommentInfo.CommentInfoEnum; import com.yeshi.fanli.entity.dynamic.DynamicInfo; import com.yeshi.fanli.entity.dynamic.GoodsEvaluate; import com.yeshi.fanli.entity.dynamic.GoodsEvaluate.EvaluateEnum; @@ -977,16 +978,20 @@ } String text = ""; CommentInfo comment = null; List<CommentInfo> comments = goodsEvaluate.getComments(); if (comments != null) { for (CommentInfo commentInfo : comments) { if (cid.equals(commentInfo.getId())) { text = commentInfo.getContent(); comment = commentInfo; break; } } } String newText = text; String newText = text; // 非通用券需要验证 if (comment != null && comment.getTypeEnum() != CommentInfoEnum.currencyCoupon) { try { newText = convertLinkManager.convertLinkFromText(text, uid, true); } catch (ConvertLinkExceptionException e) { @@ -999,6 +1004,8 @@ out.print(JsonUtil.loadFalseResult("评论生成失败")); return; } } // 替换价格 if (goodsEvaluate.getType() == EvaluateEnum.single) { fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java
@@ -955,17 +955,15 @@ throw new GoodsEvaluateException(1, "请填写券截止时间"); } if (!StringUtil.isNullOrEmpty(content) && kind != 3) { // 活动不验证 try { convertLinkManager.convertLinkFromText(content, Constant.LINK_TOKEN_VERIFY_UID, true); } catch (ConvertLinkExceptionException e) { if (ConvertLinkExceptionException.CODE_NONE != e.getCode()) { throw new GoodsEvaluateException(1, "包含不可转链的口令与链接"); } } catch (Exception e) { throw new GoodsEvaluateException(1, "包含不可转链的口令与链接"); } } // 均不验证 /* * if (!StringUtil.isNullOrEmpty(content) && kind != 3) { try { * convertLinkManager.convertLinkFromText(content, * Constant.LINK_TOKEN_VERIFY_UID, true); } catch (ConvertLinkExceptionException * e) { if (ConvertLinkExceptionException.CODE_NONE != e.getCode()) { throw new * GoodsEvaluateException(1, "包含不可转链的口令与链接"); } } catch (Exception e) { throw * new GoodsEvaluateException(1, "包含不可转链的口令与链接"); } } */ GoodsEvaluate resultObj = goodsEvaluateDao.getById(pid); if (resultObj == null) @@ -1574,6 +1572,9 @@ goodsEvaluate.setPublishTime(goodsEvaluate.getStartTime()); // 按照发布显示时间段起始时间为准。 goodsEvaluate.setPublishTime(goodsEvaluate.getStartTime()); List<CommentInfo> comments = evaluateNew.getComments(); if (comments != null && comments.size() > 0) { EvaluateEnum typeEnum = evaluateNew.getType();