package com.yonge.cooleshow.bbs.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.format.annotation.DateTimeFormat;

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

/**
 * Description
 *
 * @author liujunchi
 * @date 2022-06-11
 */
@ApiModel("已读数据")
public class MessageReadDto {

    @ApiModelProperty(value = "当前用户id",hidden = true)
    private Long userId;

    @ApiModelProperty(value = "私信对象id",required = true)
    @NotNull(message = "私信对象id不能为空 ")
    private Long sendUserId;

    @ApiModelProperty(value = "阅读时间",required = true)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @NotNull(message = "阅读时间不能为空 ")
    private Date readTime;

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getSendUserId() {
        return sendUserId;
    }

    public void setSendUserId(Long sendUserId) {
        this.sendUserId = sendUserId;
    }

    public Date getReadTime() {
        return readTime;
    }

    public void setReadTime(Date readTime) {
        this.readTime = readTime;
    }
}
