package com.gxwebsoft.shop.dto;

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

import java.io.Serializable;
import java.util.Map;

/**
 * 用户订单各状态数量统计（用于订单页徽标/统计）
 */
@Data
@Schema(name = "UserOrderStats", description = "用户订单各状态数量统计")
public class UserOrderStats implements Serializable {
    private static final long serialVersionUID = 1L;

    @Schema(description = "全部（默认过滤已取消订单：order_status != 2）")
    private Long total;

    @Schema(description = "待支付（statusFilter=0）")
    private Long waitPay;

    @Schema(description = "待发货（statusFilter=1）")
    private Long waitDeliver;

    @Schema(description = "待核销（statusFilter=2）")
    private Long waitVerify;

    @Schema(description = "待收货（statusFilter=3）")
    private Long waitReceive;

    @Schema(description = "待评价（statusFilter=4）")
    private Long waitComment;

    @Schema(description = "已完成（statusFilter=5）")
    private Long completed;

    @Schema(description = "退款/售后（statusFilter=6）")
    private Long refund;

    @Schema(description = "已删除（statusFilter=7）")
    private Long deleted;

    @Schema(description = "已取消（statusFilter=8）")
    private Long canceled;

    @Schema(description = "按 statusFilter 聚合的数量映射，key 为 \"0\"~\"8\"")
    private Map<String, Long> statusFilter;
}

