package com.crm.pay.entity;

import com.crm.rely.backend.core.constant.Constants;
import com.crm.rely.backend.core.constant.RegexpConstants;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

/**
 *
 * @author gao
 * @date 2025/12/8 10:50
 */
@Data
public class FinanceDepositUcardEntity {

    private String serial;

    /**
     * 类型：1:卡。2:钱包余额
     */
    private String type;

    private String cardNumber;

    private String cvv;

    private String pin;

    @Pattern(regexp = RegexpConstants.REGEXP_EMAIL, message = Constants.EMAIL_FORMAT_ERROR)
    @NotNull(message = Constants.EMAIL_NOT_NULL_ERROR)
    @NotBlank(message = Constants.EMAIL_NOT_NULL_ERROR)
    private String email;

    @NotNull(message = Constants.EMAIL_CODE_NOT_NULL_ERROR)
    @NotBlank(message = Constants.EMAIL_CODE_NOT_NULL_ERROR)
    private String emailCode;

}
