package com.czg.market.entity;

import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

import java.io.Serial;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 邀请与上级关联表 实体类。
 *
 * @author ww
 * @since 2025-11-06
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table("tb_shop_user_invite")
public class ShopUserInvite implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * (随机)
     */
    @Id(keyType = KeyType.Auto)
    private Long id;

    /**
     * 店铺ID
     */
    private Long shopId;

    /**
     * 店铺用户ID
     */
    private Long shopUserId;

    /**
     * 邀请人ID mk_distribution_user.id
     */
    private Long distributionUserId;

    /**
     * 邀请人上级ID mk_distribution_user.id
     */
    private Long distributionUserParentId;

    /**
     * 邀请人收益/一级分润
     */
    private BigDecimal oneIncome;

    /**
     * 邀请人上级收益/二级分润
     */
    private BigDecimal twoIncome;

    /**
     * 邀请时间
     */
    private LocalDateTime inviteTime;

}
