package com.ruoyi.generator.domain.Community;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;

/**
* 评价点赞表
* @TableName community_comment_like
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
public class CommunityCommentLike implements Serializable {

    /**
    * 唯一id
    */
    @NotNull(message="[唯一id]不能为空")
    @ApiModelProperty("唯一id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;
    /**
    * 评价id
    */
    @ApiModelProperty("评价id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long commentId;
    /**
     * 回复id
     */
    @ApiModelProperty("回复id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long replyId;
    /**
    * 点赞用户id
    */
    @ApiModelProperty("点赞用户id")
    private Long userId;
    /**
     * 是否是回复
     */
    @ApiModelProperty("是否是回复")
    @TableField(exist = false)
    private boolean isReply;
    /**
    * 创建人
    */
    @ApiModelProperty("创建人")
    private Long createBy;
    /**
    * 创建时间
    */
    @ApiModelProperty("创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    /**
    * 更新人
    */
    @ApiModelProperty("更新人")
    private Long updateBy;
    /**
    * 更新时间
    */
    @ApiModelProperty("更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

}
