package com.cf.imes.module.system.controller.admin.datasource.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

@Schema(description = "管理后台 - 系统数据源新增/修改 Request VO")
@Data
public class DataSourceSaveReqVO {

    @Schema(description = "主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "30829")
    private Long id;

    @Schema(description = "数据源名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张三")
    @NotEmpty(message = "数据源名称不能为空")
    private String name;

    @Schema(description = "sql", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "sql不能为空")
    private String sql;

    @Schema(description = "数据源类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotNull(message = "数据源类型不能为空")
    private Integer type;

}