package com.crunii.micro.domain.entity.main;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.util.Date;

/**
 * @author qiaolin
 * @version 1.0
 * @date 2023/6/29 12:17
 */
@Entity
@Table(name = "ycq_sms_info")
@DynamicInsert
@DynamicUpdate
@Getter
@Setter
@ToString
@EqualsAndHashCode(of= {"leagueId"})
@GenericGenerator(name = "idGenerator", strategy = "com.crunii.micro.core.distributed.DistributedSnowFlakeId")
@ApiModel(description = "短信记录表")
public class YcqSmsInfo {
    @Id
    @GeneratedValue(generator = "idGenerator")
    @Column(name = "id")
    @ApiModelProperty(value = "主键")
    private Long id;

    @Column(name = "phone")
    @ApiModelProperty(value = "手机号(脱敏)")
    private String phone;

    @Column(name = "content")
    @ApiModelProperty(value = "短信内容")
    private String content;

    @Column(name = "send_time")
    @ApiModelProperty(value = "发送时间")
    private Date sendTime;

    @Column(name = "code")
    @ApiModelProperty(value = "验证码")
    private String code;

    @Column(name = "biz_id")
    @ApiModelProperty(value = "发送回执ID")
    private String bizId;

    @Column(name = "message")
    @ApiModelProperty(value = "状态码的描述")
    private String message;

    @Column(name = "requestId")
    @ApiModelProperty(value = "请求id")
    private String requestId;

}
