完成评论展示相关功能

main
whb 4 months ago
parent f7a634db08
commit ac536f5a1a

@ -210,7 +210,7 @@ public class StuGoodsTradingCenterController {
@ApiOperation("商品详情页面:独购买")
@ApiOperation("商品详情页面:单")
@AnonymousAccess
@PostMapping("/purchaseGoods")
public ResultEntity getpurchaseGoods(StuPurchaseGoodsDTO stuPurchaseGoodsDTO) {
@ -228,20 +228,36 @@ public class StuGoodsTradingCenterController {
//拼团购买
tradingCenterService.groupPurchase(stuPurchaseGoodsDTO);
}
return new ResultEntity(HttpStatus.OK,"下单成功");
}
}
return new ResultEntity(HttpStatus.OK,"下单成功");
@ApiOperation("商品详情页面:商品评价")
@AnonymousAccess
@GetMapping("/evaluate")
public ResultEntity getEvaluateByGoodsId(@ApiParam("商品ID") Integer goodsId) {
return stuGoodsTradingOrderService.getEvaluateByGoodsId(goodsId);
}
@ApiOperation("商品详情页面:商品评价分页展示")
@AnonymousAccess
@GetMapping("/evaluate")
public ResultEntity getEvaluateByGoodsIdPage(@ApiParam("商品ID") Integer goodsId,
@ApiParam("当前页") @RequestParam(required = true, defaultValue = "1") Integer index,
@ApiParam("每页条数") @RequestParam(required = true, defaultValue = "20") Integer size) {
return stuGoodsTradingOrderService.getEvaluateByGoodsIdPage(goodsId,index,size);
}
}

@ -1,14 +1,19 @@
package com.sztzjy.trade.entity;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
*
*
* @author whb
* stu_goods_comment_info
*/
@Data
public class StuGoodsCommentInfo {
@ApiModelProperty(notes = "id")
private Integer id;
@ -37,8 +42,22 @@ public class StuGoodsCommentInfo {
@ApiModelProperty(notes = "商品ID")
private Integer goodsId;
@ApiModelProperty(notes = "关联评论id")
private Integer commentId;
@ApiModelProperty(notes = "点赞次数 (默认为0 未点赞)")
private Integer giveTheThumbsUp;
@ApiModelProperty(notes = "回复次数 (默认为0 未回复)")
private Integer replyFrequency;
@ApiModelProperty(notes = "举报次数 (默认为0 未举报)")
private Integer reportFrequency;
@ApiModelProperty(notes = "电脑传图 json类型type,url")
private String imageUpload;
@ApiModelProperty(notes = "评论详情")
private List<StuGoodsCommentInfo> replies = new ArrayList<StuGoodsCommentInfo>();
public Integer getId() {
return id;
@ -112,6 +131,38 @@ public class StuGoodsCommentInfo {
this.goodsId = goodsId;
}
public Integer getCommentId() {
return commentId;
}
public void setCommentId(Integer commentId) {
this.commentId = commentId;
}
public Integer getGiveTheThumbsUp() {
return giveTheThumbsUp;
}
public void setGiveTheThumbsUp(Integer giveTheThumbsUp) {
this.giveTheThumbsUp = giveTheThumbsUp;
}
public Integer getReplyFrequency() {
return replyFrequency;
}
public void setReplyFrequency(Integer replyFrequency) {
this.replyFrequency = replyFrequency;
}
public Integer getReportFrequency() {
return reportFrequency;
}
public void setReportFrequency(Integer reportFrequency) {
this.reportFrequency = reportFrequency;
}
public String getImageUpload() {
return imageUpload;
}

@ -674,6 +674,246 @@ public class StuGoodsCommentInfoExample {
addCriterion("goods_id not between", value1, value2, "goodsId");
return (Criteria) this;
}
public Criteria andCommentIdIsNull() {
addCriterion("comment_id is null");
return (Criteria) this;
}
public Criteria andCommentIdIsNotNull() {
addCriterion("comment_id is not null");
return (Criteria) this;
}
public Criteria andCommentIdEqualTo(Integer value) {
addCriterion("comment_id =", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdNotEqualTo(Integer value) {
addCriterion("comment_id <>", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdGreaterThan(Integer value) {
addCriterion("comment_id >", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdGreaterThanOrEqualTo(Integer value) {
addCriterion("comment_id >=", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdLessThan(Integer value) {
addCriterion("comment_id <", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdLessThanOrEqualTo(Integer value) {
addCriterion("comment_id <=", value, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdIn(List<Integer> values) {
addCriterion("comment_id in", values, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdNotIn(List<Integer> values) {
addCriterion("comment_id not in", values, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdBetween(Integer value1, Integer value2) {
addCriterion("comment_id between", value1, value2, "commentId");
return (Criteria) this;
}
public Criteria andCommentIdNotBetween(Integer value1, Integer value2) {
addCriterion("comment_id not between", value1, value2, "commentId");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpIsNull() {
addCriterion("give_the_thumbs_up is null");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpIsNotNull() {
addCriterion("give_the_thumbs_up is not null");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpEqualTo(Integer value) {
addCriterion("give_the_thumbs_up =", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpNotEqualTo(Integer value) {
addCriterion("give_the_thumbs_up <>", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpGreaterThan(Integer value) {
addCriterion("give_the_thumbs_up >", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpGreaterThanOrEqualTo(Integer value) {
addCriterion("give_the_thumbs_up >=", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpLessThan(Integer value) {
addCriterion("give_the_thumbs_up <", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpLessThanOrEqualTo(Integer value) {
addCriterion("give_the_thumbs_up <=", value, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpIn(List<Integer> values) {
addCriterion("give_the_thumbs_up in", values, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpNotIn(List<Integer> values) {
addCriterion("give_the_thumbs_up not in", values, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpBetween(Integer value1, Integer value2) {
addCriterion("give_the_thumbs_up between", value1, value2, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andGiveTheThumbsUpNotBetween(Integer value1, Integer value2) {
addCriterion("give_the_thumbs_up not between", value1, value2, "giveTheThumbsUp");
return (Criteria) this;
}
public Criteria andReplyFrequencyIsNull() {
addCriterion("reply_frequency is null");
return (Criteria) this;
}
public Criteria andReplyFrequencyIsNotNull() {
addCriterion("reply_frequency is not null");
return (Criteria) this;
}
public Criteria andReplyFrequencyEqualTo(Integer value) {
addCriterion("reply_frequency =", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyNotEqualTo(Integer value) {
addCriterion("reply_frequency <>", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyGreaterThan(Integer value) {
addCriterion("reply_frequency >", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyGreaterThanOrEqualTo(Integer value) {
addCriterion("reply_frequency >=", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyLessThan(Integer value) {
addCriterion("reply_frequency <", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyLessThanOrEqualTo(Integer value) {
addCriterion("reply_frequency <=", value, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyIn(List<Integer> values) {
addCriterion("reply_frequency in", values, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyNotIn(List<Integer> values) {
addCriterion("reply_frequency not in", values, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyBetween(Integer value1, Integer value2) {
addCriterion("reply_frequency between", value1, value2, "replyFrequency");
return (Criteria) this;
}
public Criteria andReplyFrequencyNotBetween(Integer value1, Integer value2) {
addCriterion("reply_frequency not between", value1, value2, "replyFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyIsNull() {
addCriterion("report_frequency is null");
return (Criteria) this;
}
public Criteria andReportFrequencyIsNotNull() {
addCriterion("report_frequency is not null");
return (Criteria) this;
}
public Criteria andReportFrequencyEqualTo(Integer value) {
addCriterion("report_frequency =", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyNotEqualTo(Integer value) {
addCriterion("report_frequency <>", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyGreaterThan(Integer value) {
addCriterion("report_frequency >", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyGreaterThanOrEqualTo(Integer value) {
addCriterion("report_frequency >=", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyLessThan(Integer value) {
addCriterion("report_frequency <", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyLessThanOrEqualTo(Integer value) {
addCriterion("report_frequency <=", value, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyIn(List<Integer> values) {
addCriterion("report_frequency in", values, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyNotIn(List<Integer> values) {
addCriterion("report_frequency not in", values, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyBetween(Integer value1, Integer value2) {
addCriterion("report_frequency between", value1, value2, "reportFrequency");
return (Criteria) this;
}
public Criteria andReportFrequencyNotBetween(Integer value1, Integer value2) {
addCriterion("report_frequency not between", value1, value2, "reportFrequency");
return (Criteria) this;
}
}
public static class Criteria extends GeneratedCriteria {

@ -0,0 +1,43 @@
package com.sztzjy.trade.entity.dto;
import com.sztzjy.trade.entity.StuGoodsCommentInfo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.ArrayList;
import java.util.List;
/**
* @author 17803
* @date 2024-11-05 15:01
*/
@Data
public class StuEvaluateInfoByGoodsIdDTO {
@ApiModelProperty(notes = "好感度")
private Integer likability;
@ApiModelProperty(notes = "词云")
private List wordCloudList;
@ApiModelProperty(notes = "全部评价数量")
private Integer evaluateAll;
@ApiModelProperty(notes = "晒图数量")
private Integer makeBlueprint;
@ApiModelProperty(notes = "追评")
private Integer followUpReview;
@ApiModelProperty(notes = "好评")
private Integer favorableComment;
@ApiModelProperty(notes = "中评")
private Integer midEvaluation;
@ApiModelProperty(notes = "差评")
private Integer badReview;
}

@ -20,6 +20,7 @@ public class StuPurchaseGoodsDTO {
@ApiModelProperty(notes = "商品类型")
private String goodsType;
@ApiModelProperty(notes = "购买数量")
private BigDecimal amount;
private String userId;

@ -1,6 +1,8 @@
package com.sztzjy.trade.service;
import com.sztzjy.trade.util.ResultEntity;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.RequestParam;
/**
* @author 17803
@ -13,4 +15,9 @@ public interface StuGoodsTradingOrderService {
//商品详情页面:看了又看功能
ResultEntity getSeeingYouOnAndOn(String userId, Integer goodsId,Integer index,Integer size,String goodsType);
}
//商品详情页面:商品评价
ResultEntity getEvaluateByGoodsId(Integer goodsId);
//商品详情页面:商品评价分页展示
ResultEntity getEvaluateByGoodsIdPage(Integer goodsId, Integer index, Integer size);
}

@ -577,8 +577,6 @@ public class StuGoodsTradingCenterServiceImpl implements StuGoodsTradingCenterSe
}else {
//添加到拼单数据中
List<StuGroupOrderInfoDTO> stuGroupOrderInfoDTOList = JSON.parseArray(splicingOrdersInfo.getParticipateInGroupBuying(), StuGroupOrderInfoDTO.class);
StuGroupOrderInfoDTO stuGroupOrderInfoDTO = new StuGroupOrderInfoDTO();
stuGroupOrderInfoDTO.setUserId(stuPurchaseGoodsDTO.getUserId());

@ -2,10 +2,12 @@ package com.sztzjy.trade.service.impl;
import cn.hutool.core.convert.Convert;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.NumberUtil;
import cn.hutool.core.util.RandomUtil;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.sztzjy.trade.entity.*;
import com.sztzjy.trade.entity.dto.StuEvaluateInfoByGoodsIdDTO;
import com.sztzjy.trade.entity.dto.StuGoodsInfoDTO;
import com.sztzjy.trade.entity.dto.StuGoodsSalesManageDTO;
import com.sztzjy.trade.mapper.*;
@ -204,6 +206,146 @@ public class StuGoodsTradingOrderServiceImpl implements StuGoodsTradingOrderServ
}
//商品详情页面:商品评价
@Override
public ResultEntity getEvaluateByGoodsId(Integer goodsId) {
StuEvaluateInfoByGoodsIdDTO evaluateInfoByGoodsIdDTO = new StuEvaluateInfoByGoodsIdDTO();
//计算好评度
StuGoodsCommentInfoExample stuGoodsCommentInfoExample = new StuGoodsCommentInfoExample();
stuGoodsCommentInfoExample.createCriteria().andGoodsIdEqualTo(goodsId).andCommentHierarchyEqualTo(0);
List<StuGoodsCommentInfo> stuGoodsCommentInfoList = stuGoodsCommentInfoMapper.selectByExampleWithBLOBs(stuGoodsCommentInfoExample);
if (!stuGoodsCommentInfoList.isEmpty()) {
//获取所有评分
//在淘宝平台上好评分数通常被认为是4分及以上。
List<Integer> ratingList = stuGoodsCommentInfoList.stream().filter(item -> item.getGoodsRating() >= 4).map(StuGoodsCommentInfo::getGoodsRating).collect(Collectors.toList());
int sum = ratingList.stream().mapToInt(Integer::intValue).sum();
//好评度
int likability = sum / stuGoodsCommentInfoList.size();
evaluateInfoByGoodsIdDTO.setLikability(likability);
//建立词云从买家评论中统计数量前10的词汇显示
List<String> goodsCommentList = stuGoodsCommentInfoList.stream().map(StuGoodsCommentInfo::getGoodsComment).collect(Collectors.toList());
// 统计每个词的频率
Map<String, Integer> wordCountMap = new HashMap<>();
for (String comment : goodsCommentList) {
// 使用正则表达式分割评论为单词
String[] words = comment.split("\\W+"); // 脱离非单词字符
for (String word : words) {
word = word.trim(); // 去除多余的空格
if (!word.isEmpty()) {
wordCountMap.put(word, wordCountMap.getOrDefault(word, 0) + 1);
}
}
}
// 排序并提取前10个词
List<Map.Entry<String, Integer>> topWords = wordCountMap.entrySet()
.stream()
.sorted((entry1, entry2) -> entry2.getValue().compareTo(entry1.getValue()))
.limit(10)
.collect(Collectors.toList());
evaluateInfoByGoodsIdDTO.setWordCloudList(topWords);
//评价详情 1-2 差评 3中评 4-5好评
//好评数量
int favorableComment = ratingList.size();
evaluateInfoByGoodsIdDTO.setFavorableComment(favorableComment);
//中评数量
int midEvaluation = (int) stuGoodsCommentInfoList.stream().filter(item -> item.getGoodsRating() == 3).map(StuGoodsCommentInfo::getGoodsRating).count();
evaluateInfoByGoodsIdDTO.setMidEvaluation(midEvaluation);
//差评
int badEvaluation = (int) stuGoodsCommentInfoList.stream().filter(item -> item.getGoodsRating() <= 2).map(StuGoodsCommentInfo::getGoodsRating).count();
evaluateInfoByGoodsIdDTO.setBadReview(badEvaluation);
//追评数量
StuGoodsCommentInfoExample stuGoodsCommentInfoExampleOne = new StuGoodsCommentInfoExample();
stuGoodsCommentInfoExampleOne.createCriteria().andGoodsIdEqualTo(goodsId).andCommentHierarchyNotEqualTo(0);
List<StuGoodsCommentInfo> stuGoodsCommentInfoListOne = stuGoodsCommentInfoMapper.selectByExampleWithBLOBs(stuGoodsCommentInfoExampleOne);
//追评数量
int followUpReview = stuGoodsCommentInfoListOne.size();
evaluateInfoByGoodsIdDTO.setFollowUpReview(followUpReview);
//晒图数量
int count = (int) stuGoodsCommentInfoList.stream().filter(item -> item.getImageUpload() != null).count();
evaluateInfoByGoodsIdDTO.setMakeBlueprint(count);
return new ResultEntity<>(HttpStatus.OK, evaluateInfoByGoodsIdDTO);
}else {
return new ResultEntity<>(HttpStatus.OK);
}
}
//商品详情页面:商品评价分页展示
@Override
public ResultEntity getEvaluateByGoodsIdPage(Integer goodsId, Integer index, Integer size) {
//新接口调用返回全部评价 查询所有包含回复评价
PageHelper.startPage(1, 20);
StuGoodsCommentInfoExample stuGoodsCommentInfoExample = new StuGoodsCommentInfoExample();
stuGoodsCommentInfoExample.createCriteria().andGoodsIdEqualTo(goodsId).andCommentHierarchyEqualTo(0);
List<StuGoodsCommentInfo> stuGoodsCommentInfoList = stuGoodsCommentInfoMapper.selectByExampleWithBLOBs(stuGoodsCommentInfoExample);
if (!stuGoodsCommentInfoList.isEmpty()) {
// 收集所有层级的回复 //递归查询
List<StuGoodsCommentInfo> allReplies = new ArrayList<>();
for (StuGoodsCommentInfo stuGoodsCommentInfo : stuGoodsCommentInfoList) {
StuGoodsCommentInfoExample stuGoodsCommentInfoExampleOne = new StuGoodsCommentInfoExample();
stuGoodsCommentInfoExampleOne.createCriteria().andGoodsIdEqualTo(goodsId).andCommentHierarchyNotEqualTo(0);
List<StuGoodsCommentInfo> stuGoodsCommentInfoListOne = stuGoodsCommentInfoMapper.selectByExampleWithBLOBs(stuGoodsCommentInfoExampleOne);
if (!stuGoodsCommentInfoListOne.isEmpty()) {
for (StuGoodsCommentInfo goodsCommentInfo : stuGoodsCommentInfoListOne) {
// 找到第一层回复
if (goodsCommentInfo.getCommentId() != null && goodsCommentInfo.getCommentId().equals(stuGoodsCommentInfo.getId())) {
// 找到第一层回复
System.out.println("Found first level reply: " + goodsCommentInfo.getGoodsComment());
// 收集所有回复
allReplies.add(goodsCommentInfo);
allReplies.addAll(findReplies(goodsCommentInfo)); // 在这里添加递归获取的回复
}
}
}
}
PageInfo<StuGoodsCommentInfo> stuGoodsCommentInfoPageInfo = new PageInfo<>(allReplies);
return new ResultEntity<>(HttpStatus.OK, stuGoodsCommentInfoPageInfo);
}
return new ResultEntity<>(HttpStatus.OK);
}
// 递归查找评论及其回复并返回所有回复的列表
public static List<StuGoodsCommentInfo> findReplies(StuGoodsCommentInfo commentInfo) {
List<StuGoodsCommentInfo> repliesList = new ArrayList<>();
for (StuGoodsCommentInfo reply : commentInfo.getReplies()) {
repliesList.add(reply);
// 递归查找这个回复下的层级评论
repliesList.addAll(findReplies(reply));
}
return repliesList;
}
}

@ -11,6 +11,10 @@
<result column="comment_hierarchy" jdbcType="INTEGER" property="commentHierarchy" />
<result column="user_id" jdbcType="VARCHAR" property="userId" />
<result column="goods_id" jdbcType="INTEGER" property="goodsId" />
<result column="comment_id" jdbcType="INTEGER" property="commentId" />
<result column="give_the_thumbs_up" jdbcType="INTEGER" property="giveTheThumbsUp" />
<result column="reply_frequency" jdbcType="INTEGER" property="replyFrequency" />
<result column="report_frequency" jdbcType="INTEGER" property="reportFrequency" />
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.sztzjy.trade.entity.StuGoodsCommentInfo">
<result column="image_upload" jdbcType="LONGVARCHAR" property="imageUpload" />
@ -75,7 +79,8 @@
</sql>
<sql id="Base_Column_List">
id, order_number, goods_rating, goods_comment, anonymous_evaluation, create_time,
comment_hierarchy, user_id, goods_id
comment_hierarchy, user_id, goods_id, comment_id, give_the_thumbs_up, reply_frequency,
report_frequency
</sql>
<sql id="Blob_Column_List">
image_upload
@ -132,11 +137,13 @@
insert into stu_goods_comment_info (id, order_number, goods_rating,
goods_comment, anonymous_evaluation, create_time,
comment_hierarchy, user_id, goods_id,
image_upload)
comment_id, give_the_thumbs_up, reply_frequency,
report_frequency, image_upload)
values (#{id,jdbcType=INTEGER}, #{orderNumber,jdbcType=VARCHAR}, #{goodsRating,jdbcType=INTEGER},
#{goodsComment,jdbcType=VARCHAR}, #{anonymousEvaluation,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{commentHierarchy,jdbcType=INTEGER}, #{userId,jdbcType=VARCHAR}, #{goodsId,jdbcType=INTEGER},
#{imageUpload,jdbcType=LONGVARCHAR})
#{commentId,jdbcType=INTEGER}, #{giveTheThumbsUp,jdbcType=INTEGER}, #{replyFrequency,jdbcType=INTEGER},
#{reportFrequency,jdbcType=INTEGER}, #{imageUpload,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sztzjy.trade.entity.StuGoodsCommentInfo">
insert into stu_goods_comment_info
@ -168,6 +175,18 @@
<if test="goodsId != null">
goods_id,
</if>
<if test="commentId != null">
comment_id,
</if>
<if test="giveTheThumbsUp != null">
give_the_thumbs_up,
</if>
<if test="replyFrequency != null">
reply_frequency,
</if>
<if test="reportFrequency != null">
report_frequency,
</if>
<if test="imageUpload != null">
image_upload,
</if>
@ -200,6 +219,18 @@
<if test="goodsId != null">
#{goodsId,jdbcType=INTEGER},
</if>
<if test="commentId != null">
#{commentId,jdbcType=INTEGER},
</if>
<if test="giveTheThumbsUp != null">
#{giveTheThumbsUp,jdbcType=INTEGER},
</if>
<if test="replyFrequency != null">
#{replyFrequency,jdbcType=INTEGER},
</if>
<if test="reportFrequency != null">
#{reportFrequency,jdbcType=INTEGER},
</if>
<if test="imageUpload != null">
#{imageUpload,jdbcType=LONGVARCHAR},
</if>
@ -241,6 +272,18 @@
<if test="record.goodsId != null">
goods_id = #{record.goodsId,jdbcType=INTEGER},
</if>
<if test="record.commentId != null">
comment_id = #{record.commentId,jdbcType=INTEGER},
</if>
<if test="record.giveTheThumbsUp != null">
give_the_thumbs_up = #{record.giveTheThumbsUp,jdbcType=INTEGER},
</if>
<if test="record.replyFrequency != null">
reply_frequency = #{record.replyFrequency,jdbcType=INTEGER},
</if>
<if test="record.reportFrequency != null">
report_frequency = #{record.reportFrequency,jdbcType=INTEGER},
</if>
<if test="record.imageUpload != null">
image_upload = #{record.imageUpload,jdbcType=LONGVARCHAR},
</if>
@ -260,6 +303,10 @@
comment_hierarchy = #{record.commentHierarchy,jdbcType=INTEGER},
user_id = #{record.userId,jdbcType=VARCHAR},
goods_id = #{record.goodsId,jdbcType=INTEGER},
comment_id = #{record.commentId,jdbcType=INTEGER},
give_the_thumbs_up = #{record.giveTheThumbsUp,jdbcType=INTEGER},
reply_frequency = #{record.replyFrequency,jdbcType=INTEGER},
report_frequency = #{record.reportFrequency,jdbcType=INTEGER},
image_upload = #{record.imageUpload,jdbcType=LONGVARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
@ -275,7 +322,11 @@
create_time = #{record.createTime,jdbcType=TIMESTAMP},
comment_hierarchy = #{record.commentHierarchy,jdbcType=INTEGER},
user_id = #{record.userId,jdbcType=VARCHAR},
goods_id = #{record.goodsId,jdbcType=INTEGER}
goods_id = #{record.goodsId,jdbcType=INTEGER},
comment_id = #{record.commentId,jdbcType=INTEGER},
give_the_thumbs_up = #{record.giveTheThumbsUp,jdbcType=INTEGER},
reply_frequency = #{record.replyFrequency,jdbcType=INTEGER},
report_frequency = #{record.reportFrequency,jdbcType=INTEGER}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
@ -307,6 +358,18 @@
<if test="goodsId != null">
goods_id = #{goodsId,jdbcType=INTEGER},
</if>
<if test="commentId != null">
comment_id = #{commentId,jdbcType=INTEGER},
</if>
<if test="giveTheThumbsUp != null">
give_the_thumbs_up = #{giveTheThumbsUp,jdbcType=INTEGER},
</if>
<if test="replyFrequency != null">
reply_frequency = #{replyFrequency,jdbcType=INTEGER},
</if>
<if test="reportFrequency != null">
report_frequency = #{reportFrequency,jdbcType=INTEGER},
</if>
<if test="imageUpload != null">
image_upload = #{imageUpload,jdbcType=LONGVARCHAR},
</if>
@ -323,6 +386,10 @@
comment_hierarchy = #{commentHierarchy,jdbcType=INTEGER},
user_id = #{userId,jdbcType=VARCHAR},
goods_id = #{goodsId,jdbcType=INTEGER},
comment_id = #{commentId,jdbcType=INTEGER},
give_the_thumbs_up = #{giveTheThumbsUp,jdbcType=INTEGER},
reply_frequency = #{replyFrequency,jdbcType=INTEGER},
report_frequency = #{reportFrequency,jdbcType=INTEGER},
image_upload = #{imageUpload,jdbcType=LONGVARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
@ -335,7 +402,11 @@
create_time = #{createTime,jdbcType=TIMESTAMP},
comment_hierarchy = #{commentHierarchy,jdbcType=INTEGER},
user_id = #{userId,jdbcType=VARCHAR},
goods_id = #{goodsId,jdbcType=INTEGER}
goods_id = #{goodsId,jdbcType=INTEGER},
comment_id = #{commentId,jdbcType=INTEGER},
give_the_thumbs_up = #{giveTheThumbsUp,jdbcType=INTEGER},
reply_frequency = #{replyFrequency,jdbcType=INTEGER},
report_frequency = #{reportFrequency,jdbcType=INTEGER}
where id = #{id,jdbcType=INTEGER}
</update>
</mapper>
Loading…
Cancel
Save