123456789101112131415161718192021222324252627 |
- package request
- import (
- pb "sghgogs.com/micro/shopping-service/proto"
- "time"
- )
- // Pending 待支付 订单已创建,但尚未支付。
- // Processing 支付中 支付请求已经提交,正在处理中。
- // Paid 支付成功 支付已成功完成。
- // Failed 支付失败 支付尝试失败。
- // Canceled 取消支付 用户或系统取消了支付。
- // Refunding 退款中 用户请求退款,退款正在处理中。
- // Refunded 已退款 退款已成功完成。
- // Partially Refunding 部分退款中 用户请求部分退款,部分退款正在处理中。
- // Partially Refunded 已部分退款 部分退款已成功完成。
- // Payment 支付表
- type Payment struct {
- ID int64 `gorm:"primary_key;not_null;auto_increment;" json:"id"`
- OrderID int64 `gorm:"not null" json:"order_id"` // 订单ID
- Amount int64 `json:"amount"` // 支付金额
- Status pb.PaymentStatusEnum `json:"status"` // 支付状态
- PaymentMethod pb.PaymentMethodEnum `json:"payment_method"` // 支付方式
- CreatedAt time.Time `json:"created_at"`
- UpdatedAt *time.Time `json:"updated_at"`
- }
|