# AdjEmailTargetDTO.java

    package cloud.wconnect.frontoffice.pojo.dto.adjustment;

    import lombok.*;
    import lombok.experimental.Accessors;
    import org.hibernate.validator.constraints.Length;
    import org.hibernate.validator.constraints.Range;

    import jakarta.validation.constraints.NotNull;
    import java.io.Serializable;

    /**
     * @author lichen
     * @description 邮件目标对象DTO
     */
    @Data
    @Builder
    @NoArgsConstructor
    @AllArgsConstructor
    @EqualsAndHashCode(callSuper = false)
    @Accessors(chain = true)
    public class AdjEmailTargetDTO implements Serializable {

        private static final long serialVersionUID = 1L;

        /**
         * 主键id
         */
        private Integer id;

        /**
         * 邮件配置id
         */
        private Integer configId;

        /**
         * 通知类型
         */
        private Integer targetType;

        /**
         * 用户来源1：user 2: manual 3:usergroup
         */
        @Range(min = 1, max = 3, message = "source must between in [1:user 2:manual 3:usergroup]")
        @NotNull(message = "The source cannot be null")
        private Integer source;

        /**
         * 身份id。用户来源是manual时，此值为0
         */
        @NotNull(message = "The identityId cannot be null")
        private Integer identityId;

        /**
         * 身份名称
         */
        @Length(max = 60, message = "The identityName is limit 60 characters")
        private String identityName;

        /**
         * 邮箱地址
         */
        @Length(max = 60, message = "The email is limit 60 characters")
        private String email;

        /**
         * 调账类型
         */
        @Range(min = 0, max = 3, message = "The requestType must between in [0:Other 1:Sales 2:Front Desk 3:Accounting]")
        private Integer requestType;

    }