package com.greenorange.promotion.model.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

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

/**
 * 用户绩效汇总表
 * @TableName user_performance_summary
 */
@TableName(value ="user_performance_summary")
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class UserPerformanceSummary implements Serializable {
    /**
     * 用户ID
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 订单总金额
     */
    private BigDecimal totalAmount;

    /**
     * 净成交
     */
    private BigDecimal netAmount;

    /**
     * 推广人数
     */
    private Integer promoCount;

    /**
     * 员工数量
     */
    private Integer empCount;

    /**
     * 下单数量
     */
    private Integer orderCount;

    /**
     * 待释放
     */
    private BigDecimal toRelease;

    /**
     * 可结算
     */
    private BigDecimal toSettle;

    /**
     * 已结算
     */
    private BigDecimal settled;

    /**
     * 已回退
     */
    private BigDecimal refunded;

    /**
     * 用户id
     */
    private Long userId;

    /**
     * 是否删除
     */
    private Integer isDelete;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 更新时间
     */
    private Date updateTime;

    @Serial
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}