package top.continew.admin.business.model.req;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import top.continew.starter.extension.crud.model.req.BaseReq;

import java.io.Serial;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 创建课程信息
 *
 * @author 张波
 * @since 2024/10/22 11:58
 */
@Data
public class CoursesReq extends BaseReq {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 课程名称
     */
    @Schema(description = "课程名称")
    @NotNull(message = "课程名称不能为空")
    private String name;

    /**
     * 描述
     */
    @Schema(description = "课程简介")
    @NotNull(message = "课程简介不能为空")
    private String description;

    /**
     * 班级
     */
    @Schema(description = "班级")
    @NotNull(message = "班级不能为空")
    private String className;

    /**
     * 封面
     */
    @Schema(description = "封面Url")
    @NotNull(message = "封面Url不能为空")
    private String coverImage;

    /**
     * 开始时间
     */
    @Schema(description = "开始时间")
    @NotNull(message = "开始时间不能为空")
    private LocalDateTime startTime;

    /**
     * 结束时间
     */
    @Schema(description = "结束时间")
    @NotNull(message = "结束时间不能为空")
    private LocalDateTime endTime;

    @Schema(description = "关联学生列表")
    @NotNull(message = "关联学生不能为空")
    private List<CourseUserReq> users;
}