package dto

// ClientRechargeOrderListRequest C6 充值订单列表请求
type ClientRechargeOrderListRequest struct {
	Page     int `json:"page" query:"page" description:"页码"`
	PageSize int `json:"page_size" query:"page_size" description:"每页数量"`
	Status   int `json:"status" query:"status" description:"状态过滤 (0:待支付, 1:已支付, 2:已关闭, 3:已退款)"`
}

// ClientRechargeOrderListItem C6 充值订单列表项
type ClientRechargeOrderListItem struct {
	RechargeOrderID    uint   `json:"recharge_order_id" description:"充值订单ID"`
	RechargeOrderNo    string `json:"recharge_order_no" description:"充值订单号"`
	Amount             int64  `json:"amount" description:"充值金额（分）"`
	Status             int    `json:"status" description:"状态 (0:待支付, 1:已支付, 2:已关闭, 3:已退款)"`
	StatusName         string `json:"status_name" description:"状态名称（中文）"`
	AutoPurchaseStatus string `json:"auto_purchase_status" description:"自动购包状态 (pending/success/failed)"`
	CreatedAt          string `json:"created_at" description:"创建时间"`
}

// ClientRechargeOrderDetail C7 充值订单详情
type ClientRechargeOrderDetail struct {
	RechargeOrderID    uint                               `json:"recharge_order_id" description:"充值订单ID"`
	RechargeOrderNo    string                             `json:"recharge_order_no" description:"充值订单号"`
	Amount             int64                              `json:"amount" description:"充值金额（分）"`
	Status             int                                `json:"status" description:"状态 (0:待支付, 1:已支付, 2:已关闭, 3:已退款)"`
	StatusName         string                             `json:"status_name" description:"状态名称（中文）"`
	AutoPurchaseStatus string                             `json:"auto_purchase_status" description:"自动购包状态"`
	LinkedPackageIDs   interface{}                        `json:"linked_package_ids" description:"关联套餐ID列表"`
	CreatedAt          string                             `json:"created_at" description:"创建时间"`
	PaidAt             string                             `json:"paid_at,omitempty" description:"支付时间"`
	Payments           []ClientRechargeOrderPaymentDetail `json:"payments,omitempty" description:"支付记录列表"`
}

// ClientRechargeOrderPaymentDetail 充值订单支付记录详情
type ClientRechargeOrderPaymentDetail struct {
	PaymentID         uint   `json:"payment_id" description:"支付记录ID"`
	PaymentNo         string `json:"payment_no" description:"支付单号"`
	PaymentMethod     string `json:"payment_method" description:"支付方式 (wechat/alipay/wallet)"`
	Amount            int64  `json:"amount" description:"支付金额（分）"`
	Status            int    `json:"status" description:"状态 (0:待支付, 1:已支付, 2:已失败, 3:已退款)"`
	StatusName        string `json:"status_name" description:"状态名称（中文）"`
	ThirdPartyTradeNo string `json:"third_party_trade_no,omitempty" description:"第三方交易号"`
	PaidAt            string `json:"paid_at,omitempty" description:"支付时间"`
	CreatedAt         string `json:"created_at" description:"创建时间"`
}
