All Downloads are FREE. Search and download functionalities are using the official Maven repository.

k.e.book.ddh.entity.CcSmsDO Maven / Gradle / Ivy


package k.e.book.ddh.entity;


import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.beans.BeanUtils;

import java.util.Date;
/**
 * @author kk
 * @date 2023-05-21 11:01
 */
@EqualsAndHashCode(callSuper = false)
@Data
@TableName("cc_sms")
@ApiModel(value="CcSmsDO", description="CcSms")
public class CcSmsDO extends Model  {
    private static final long serialVersionUID = 1L;


    @TableId(value = "id", type = IdType.AUTO)
    private Long id;


    /**
     * 事件
     */
    @TableField("event")
    private String event;
    /**
     * 手机号
     */
    @TableField("mobile")
    private String mobile;
    /**
     * 验证码
     */
    @TableField("templates/code")
    private String code;
    /**
     * 验证次数
     */
    @TableField("times")
    private Integer times;
    /**
     * IP
     */
    @TableField("ip")
    private String ip;
    /**
     * 创建时间
     */
    @TableField("createtime")
    private Long createtime;
    /**
     * createdAt
     */
    @TableField("created_at")
    private Date createdAt;
    /**
     * updatedAt
     */
    @TableField("updated_at")
    private Date updatedAt;
    /**
     * deletedAt
     */
    @TableField("deleted_at")
    private Date deletedAt;

    public static CcSmsVO toVO(CcSmsDO ccSmsDO) {
        if(ccSmsDO == null){
            return null;
        }
        CcSmsVO ccSmsVO = new CcSmsVO();
        BeanUtils.copyProperties(ccSmsDO, ccSmsVO);
        return ccSmsVO;
    }

    public static CcSmsDO toDO(CcSmsAddDTO ccSmsAddDTO) {
        if (ccSmsAddDTO == null) {
            return null;
        }
        CcSmsDO ccSmsDO = new CcSmsDO();
        BeanUtils.copyProperties(ccSmsAddDTO, ccSmsDO);
        return ccSmsDO;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy