package com.shkj.wms.bo;

import com.shkj.common.core.domain.BaseEntity;
import com.shkj.common.core.validate.AddGroup;
import com.shkj.common.core.validate.EditGroup;
import com.shkj.wms.domain.BasRuleDetail;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.List;


/**
 * 编码规则业务对象 bas_rule
 *
 * @author j.liang
 * @date 2022-12-08
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class BasRuleBo extends BaseEntity {

    /**
     * 规则主键
     */
    @NotNull(message = "规则主键不能为空", groups = { EditGroup.class })
    private Long ruleId;

    /**
     * 规则名称
     */
    @NotBlank(message = "规则名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String ruleName;

    /**
     * 规则编号
     */
    @NotBlank(message = "规则编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String ruleNum;

    /**
     * 规则描述
     */
    @NotBlank(message = "规则描述不能为空", groups = { AddGroup.class, EditGroup.class })
    private String description;

    /**
     * 规则状态（0正常 1停用）
     */
    private String status;

    /**
     * 规则项
     */
    private String ruleItem;

    /**
     * 规则值
     */
    private String ruleValue;

    /**
     * 规则长度
     */
    private Long ruleLength;

    /**
     * 归零规则（0每天 1每周 2每月 3每年 4从不）
     */
    private String ruleZero;

    /**
     * 补零规则（0前置补零 1不补零）
     */
    private String ruleZeroize;

    /**
     * 按变量归零（0是 1否）
     */
    private String ruleVariable;

    /**
     * 规则详情list
     */
    private List<BasRuleDetail> list;


}
