package com.hzs.common.domain.system.config;

import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hzs.common.core.annotation.BigDecimalFormat;
import com.hzs.common.core.annotation.Excel;
import com.hzs.common.core.annotation.Transaction;
import com.hzs.common.core.constant.EnumsPrefixConstants;
import com.hzs.common.core.web.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.math.BigDecimal;

/**
 * 等级配置表
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("BD_GRADE")
@KeySequence("BD_GRADE_SEQ")
public class BdGrade extends BaseEntity {


    @TableId("PK_ID")
    private Integer pkId;

    /**
     * 等级名称
     */
    @Excel(name = "注册等级", sort = 1)
    @TableField("GRADE_NAME")
    private String gradeName;


    /**
     * 翻译key
     */
    @TableField("PK_TRANSACTION")
    private Integer pkTransaction;

    /**
     * 等级值
     */
    @TableField("GRADE_VALUE")
    private Integer gradeValue;

    /**
     * 统计值
     */
    @Transaction(transactionKey = EnumsPrefixConstants.STATISTICAL_VALUE)
    @TableField("CENSUS_VALUE")
    private Integer censusValue;

    /**
     * 结算值 注册金额/业绩
     */
    @Excel(name = "注册金额/业绩")
    @TableField("START_VALUE")
    @BigDecimalFormat()
    private BigDecimal startValue;
    /**
     * 注册权限
     */
    @Transaction(transactionKey = EnumsPrefixConstants.REGISTRATION_AUTHORITY)
    @TableField("REGISTER_AUTHORITY")
    private Integer registerAuthority;

    /**
     * 真实奖衔
     */
    @Transaction(transactionKey = EnumsPrefixConstants.KEY_AWARD)
    @TableField("PK_AWARDS")
    private Integer pkAwards;
    /**
     * 首购计算  EDealerYesNo
     */
    @TableField("FIRST_CALCULATE")
    @Transaction(transactionKey = EnumsPrefixConstants.DEALER_YES_NO)
    private Integer firstCalculate;
    /**
     * 首购考核  EAssessmentType
     */
    @TableField("FIRST_ASSESS")
    @Transaction(transactionKey = EnumsPrefixConstants.ASSESSMENT_TYPE)
    private Integer firstAssess;

    /**
     * 拓展封顶
     */
    @TableField("EXPAND_CAPPING")
    private BigDecimal expandCapping;

    /**
     * 拓展比例
     */
    @TableField("EXPAND_RATIO")
    private BigDecimal expandRatio;


    /**
     * 复购计算  EDealerYesNo
     */
    @TableField("REPURCHASE_CALCULATE")
    @Transaction(transactionKey = EnumsPrefixConstants.DEALER_YES_NO)
    private Integer repurchaseCalculate;

    /**
     * 复购考核  EAssessmentType
     */
    @TableField("REPURCHASE_ASSESS")
    @Transaction(transactionKey = EnumsPrefixConstants.ASSESSMENT_TYPE)
    private Integer repurchaseAssess;

    /**
     * 复购拓展封顶
     */
    @TableField("Repurchase_CAPPING")
    private BigDecimal repurchaseCapping;

    /**
     * 复购拓展比例
     */
    @TableField("REPURCHASE_RATIO")
    private BigDecimal repurchaseRatio;
    /**
     * 图片
     */
    @TableField("IMAGE")
    private String image;

    /**
     * 色值
     */
    @TableField("COLOR")
    private String color;

    /**
     * 启用状态 EnableStatus
     */
    @TableField("ENABLE_STATE")
    private Integer enableState;

    /**
     * 图标
     */
    @TableField("ICON")
    private String icon;

    /**
     * 系统类型（2=新零售）
     */
    @TableField("SYSTEM_TYPE")
    private Integer systemType;

    /**
     * 购买盒数
     */
    @TableField("BOX_NUMBER")
    private Integer boxNumber;

    /**
     * 累计盒数
     */
    @TableField("BOX_TOTAL")
    private Integer boxTotal;

    /**
     * 小市场盒数
     */
    @TableField("BOX_SMALL_TOTAL")
    private Integer boxSmallTotal;

    /**
     * 购买价格
     */
    @TableField("BUY_PRICE")
    private BigDecimal buyPrice;

    /**
     * 代数
     */
    @TableField("ALGEBRA")
    private Integer algebra;

    /**
     * 第一代平级(奖金)
     */
    @TableField("first_algebra")
    private BigDecimal firstAlgebra;

    /**
     * 第二代平级(奖金)
     */
    @TableField("second_algebra")
    private BigDecimal secondAlgebra;

    /**
     * 第三代平级(奖金)
     */
    @TableField("third_algebra")
    private BigDecimal thirdAlgebra;
}
