package com.hz.pm.api.meeting.entity.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 * MeetingBasicDto
 * </p>
 *
 * @author WendyYang
 * @since 09:35 2022/7/26
 */
@Data
@ApiModel("会议基本信息")
public class MeetingBasicDTO {

    @NotEmpty(message = "会议名称不能为空")
    @ApiModelProperty("会议名称")
    private String name;

    @NotEmpty(message = "会议类型不能为空")
    @ApiModelProperty("会议类型")
    private String type;

    @NotNull(message = "开始时间不能为空")
    @ApiModelProperty("开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private LocalDateTime startTime;

    @NotNull(message = "结束时间不能为空")
    @ApiModelProperty("结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private LocalDateTime endTime;

    @ApiModelProperty("评审耗时：1 半天、2 一天")
    private Integer meetingUsageTime;

    @ApiModelProperty("评委出席时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private LocalDateTime judgesAttendanceTime;

    @NotEmpty(message = "评审地点不能为空")
    @ApiModelProperty("评审地点")
    private String meetingAddress;

    @NotBlank(message = "短信通知签名不能为空")
    @Length(min = 1, max = 20, message = "短信通知签名无效")
    @ApiModelProperty("短信通知签名")
    private String smsNotifySign;

    @NotEmpty(message = "联系人不能为空")
    @ApiModelProperty("联系人")
    private String connecter;

    @NotEmpty(message = "联系方式不能为空")
    @ApiModelProperty("联系方式")
    private String contact;

    @ApiModelProperty("是否是系统内部项目")
    @NotNull(message = "是否系统内项目不能为空")
    private Boolean isInnerProject;

    @ApiModelProperty("内部项目ID")
    private List<ProjectIdCodeDTO> innerProjects;

    @ApiModelProperty("外部项目")
    private List<MeetingReviewProjectDTO> projects;

    @ApiModelProperty("会议说明")
    private String description;

    @ApiModelProperty("备注")
    private String remark;

    @ApiModelProperty("相关材料")
    private String attachFiles;

}
