package cn.superdesk.uniorder.dao.entity.base;

import lombok.Data;
import lombok.ToString;
import org.springframework.data.annotation.Transient;

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

@Data
@ToString
public class UnifiedOrderCredit implements Serializable {
    private Long id;

    private String orderSn;

    private Long orderId;

    private Long goodsId;

    private Long outSnapshotOrderCreditId;

    /**
     * 积分类型id(如果是微信支付,显示0)
     */
    private Integer creditType;

    /**
     * 积分名称
     */
    private String creditName;

    /**
     * 积分变动类型(1充值 2消费 3退款)
     */
    private Integer dailyAccountType;

    /**
     * 积分批次 (如果是微信支付,显示 wechat)
     */
    private String batchs;

    /**
     * 消耗 积分额度 积分支付金额
     */
    private BigDecimal balance;

    /**
     * 所属企业id(买家)
     */
    private Long enterpriseId;

    /**
     * 会员(买家)id
     */
    private Long memberId;

    /**
     * 0未支付  1已支付
     */
    private Integer payStatus;

    /**
     * 1积分支付  2微信支付
     */
    private Integer payType;

    /**
     * 客户对账锁定:0-正常;1-销定
     */
    private Integer creditLockingCustomer;

    /**
     * 供应商对账锁定:0-正常;1-销定
     */
    private Integer creditLockingSupplier;

    /**
     * 客户对账:1-已对账;2-未对账
     */
    private Integer accountingStateCustomer;

    /**
     * 供应商对账:1-已对账;2-未对账
     */
    private Integer accountingStateSupplier;

    /**
     * 发票申请状态 是否已申请 0-未申请;1-已申请;
     */
    private Integer invoiceApplyStatus;

    /**
     * 开票状态 是否已登记开票 0-未登记;1-已登记;
     */
    private Integer invoiceMakeStatus;

    /**
     * 回款状态 是否回款 0-未回款;1-已回款;
     */
    private Integer backStatus;

    private Integer direction;

    private Date createTime;

    private Long createUserId;

    private Date updateTime;

    private Long updateUserId;

    @Transient
    private Long qchGoodsId;


    /**
     * 应收统计状态 9历史 0未统计 1已统计
     */
    private Integer receivableStatisticsState;

    /**
     * 应付统计状态 9历史 0未统计 1已统计
     */
    private Integer payableStatisticsState;


    private static final long serialVersionUID = 1L;
}
