package com.crm.rely.backend.core.entity.web.book;

import com.crm.rely.backend.core.constant.ManagerConstant;
import com.crm.rely.backend.core.entity.base.BaseAddEntity;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.NotNull;

@Data
public class WebEbookAddEntity extends BaseAddEntity {

    @NotNull(message = ManagerConstant.TITLE_NOT_NULL)
    @NotBlank(message = ManagerConstant.TITLE_NOT_NULL)
    private String title;

    @NotNull(message = ManagerConstant.LANG_NOT_NULL)
    @NotBlank(message = ManagerConstant.LANG_NOT_NULL)
    private String lang;

    private String coverImage;

    private String bookUrl;

    @NotNull(message = ManagerConstant.CONTENT_NOT_NULL)
    @NotBlank(message = ManagerConstant.CONTENT_NOT_NULL)
    private String content;


    @NotNull(message = ManagerConstant.VALID_NOT_NULL)
    private Integer valid;


}
