
package com.tmerclub.cloud.api.order.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;

/**
 * @author Pineapple
 * @date 2021/5/21 16:06
 */
@Data
public class OrderProdEffectRespVO implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;
    /**
     * 商品id
     */
    @Schema(description = "商品id")
    private Long spuId;
    /**
     * 下单人数
     */
    @Schema(description = "下单人数")
    private Integer placeOrderPerson;
    /**
     * 支付人数
     */
    @Schema(description = "支付人数")
    private Integer payPerson;
    /**
     * 下单商品件数
     */
    @Schema(description = "下单商品件数")
    private Integer placeOrderNum;
    /**
     * 支付商品件数
     */
    @Schema(description = "支付商品件数")
    private Integer payNum;
    /**
     * 商品下单金额
     */
    @Schema(description = "商品下单金额")
    private Double placeOrderAmount;
    /**
     * 商品支付金额
     */
    @Schema(description = "商品支付金额")
    private Double payAmount;

    /**
     * 支付成功订单数，计算退款率使用
     */
    private Integer payOrderNum;

    public OrderProdEffectRespVO() {
    }

    public OrderProdEffectRespVO(Long spuId, Integer placeOrderPerson, Integer payPerson, Integer placeOrderNum, Integer payNum, Double placeOrderAmount, Double payAmount, Integer payOrderNum) {
        this.spuId = spuId;
        this.placeOrderPerson = placeOrderPerson;
        this.payPerson = payPerson;
        this.placeOrderNum = placeOrderNum;
        this.payNum = payNum;
        this.placeOrderAmount = placeOrderAmount;
        this.payAmount = payAmount;
        this.payOrderNum = payOrderNum;
    }


    @Override
    public String toString() {
        return "OrderProdEffectRespVO{" +
                "spuId=" + spuId +
                ", placeOrderPerson=" + placeOrderPerson +
                ", payPerson=" + payPerson +
                ", placeOrderNum=" + placeOrderNum +
                ", payNum=" + payNum +
                ", placeOrderAmount=" + placeOrderAmount +
                ", payAmount=" + payAmount +
                ", payOrderNum=" + payOrderNum +
                '}';
    }
}
