package org.dromara.system.domain.info;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.tenant.core.TenantEntity;

import java.io.Serial;
import java.util.Date;
import java.util.List;

/**
 * @Author: tjf
 * @Date: 2023/8/18 9:58
 * @Describe:
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("info_pinglun")
public class InfoPingLun extends TenantEntity {
    @Serial
    private static final long serialVersionUID = 1L;

    /** 校园安全信息评论id */
    @TableId(value = "info_pinglun_id")
    private Long infoPingLunId;

    /** 校园安全信息id */

    private Long infoId;

    /** 校园安全信息父id */


    private Long infoPingLunParent;

    /** 评论内容 */

    private String infoPingLunContent;

    /** 头像地址 */

    private String avatar;

    /** 评论人id */

    private Long infoPingLunUserId;

    /** 评论人名称 */

    private String infoPingLunUserName;

    /** 被评论人id */

    private Long infoPingLunQuiltUserId;

    /** 被评论人名称 */

    private String infoPingLunQuiltUserName;

    /** 评论时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")

    private Date pingLunTime;

    /** 评论类型 1:评论 2:回复 */

    private String infoPingLunType;

    /** 是否通过 N:未通过 Y:通过 */

    private String infoPingLunExamine;

    /**
     * 对此评论的回复集合
     */
    @TableField(exist = false)
    private List<InfoPingLun> infoPingLunList;
}
