package shop.alien.entity.store;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * 评论申诉表
 *
 * @author system
 * @since 2025-01-XX
 */
@Data
@JsonInclude
@EqualsAndHashCode(callSuper = false)
@TableName("comment_appeals")
@ApiModel(value = "CommentAppeal对象", description = "评论申诉表")
public class CommentAppeal extends Model<CommentAppeal> {

    @ApiModelProperty(value = "主键id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "评论id")
    @TableField("comment_id")
    private Integer commentId;

    @ApiModelProperty(value = "评论内容")
    @TableField("comment_info")
    private String commentInfo;

    @ApiModelProperty(value = "申诉理由")
    @TableField("appeal_reason")
    private String appealReason;

    @ApiModelProperty(value = "申诉处理状态, 0:待处理, 1:已通过, 2:已驳回")
    @TableField("status")
    private Integer status;

    @ApiModelProperty(value = "删除标记, 0:未删除, 1:已删除")
    @TableField("delete_flag")
    @TableLogic
    private Integer deleteFlag;

    @ApiModelProperty(value = "创建时间")
    @TableField(value = "created_time", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createdTime;

    @ApiModelProperty(value = "创建人ID")
    @TableField(value = "created_user_id", fill = FieldFill.INSERT)
    private Integer createdUserId;

    @ApiModelProperty(value = "更新时间")
    @TableField(value = "updated_time", fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updatedTime;

    @ApiModelProperty(value = "更新人ID")
    @TableField(value = "updated_user_id", fill = FieldFill.INSERT_UPDATE)
    private Integer updatedUserId;

    @ApiModelProperty(value = "申诉时间")
    @TableField(value = "appeal_time", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date appealTime;

    @ApiModelProperty(value = "图片路径")
    @TableField("img_url")
    private String imgUrl;

    @ApiModelProperty(value = "申诉审核通过 驳回时间")
    @TableField(value = "appeal_review_time", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date appealReviewTime;

    @ApiModelProperty(value = "审核原因")
    @TableField("review_reasons")
    private String reviewReasons;

    @ApiModelProperty(value = "申诉审核单号")
    @TableField("appeal_number")
    private String appealNumber;

    @ApiModelProperty(value = "申诉人id")
    @TableField("lawyer_user_id")
    private String lawyerUserId;

    @ApiModelProperty(value = "订单ID")
    @TableField("order_id")
    private Integer orderId;

    @ApiModelProperty(value = "评价图片")
    @TableField("review_images")
    private String reviewImages;
}

