package com.ruoyi.base.protocol.domain.bo;

import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import com.ruoyi.common.filepathsplicing.FilePathRich;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;

/**
 * 协议管理业务对象 tb_protocol
 *
 * @author xiechao
 * @date 2023-12-21
 */
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel("协议业务对象")
public class ProtocolBo extends BaseEntity {

    /**
     * ID
     */
    @ApiModelProperty(value = "ID")
    private Integer id;

    /**
     * 协议code
     *     用户协议：user_protocol
     *     服务协议：service_protocol
     */
    @ApiModelProperty(value = "协议code 用户协议：user_protocol 服务协议：service_protocol", required = true)
    @NotBlank(message = "协议code不能为空", groups = { AddGroup.class, EditGroup.class })
    private String protocolCode;

    /**
     * 协议内容
     */
    @FilePathRich
    @ApiModelProperty(value = "协议内容", required = true)
    @NotBlank(message = "协议内容不能为空", groups = { AddGroup.class, EditGroup.class })
    private String protocolContent;

}
