fix:购物车下单

This commit is contained in:
momo
2023-09-21 10:30:36 +08:00
parent 137919a4d7
commit 4f61702e14
9 changed files with 171 additions and 19 deletions

View File

@@ -7,20 +7,6 @@ import (
// TODO: 使用model的属性做你想做的
type NewFsOrder struct {
Id int64 `gorm:"primary_key;default:0;auto_increment;" json:"id"` // 订单ID
UserId *int64 `gorm:"index;default:0;" json:"user_id"` // 用户ID
DeliveryMethod *int64 `gorm:"index;default:0;" json:"delivery_method"` // 物流类型
OrderSn *string `gorm:"index;default:'';" json:"order_sn"` //
OrderSource *string `gorm:"default:'';" json:"order_source"` //
Status *int64 `gorm:"index;default:0;" json:"status"` // 订单状态
PayStatus *int64 `gorm:"default:0;" json:"pay_status"` // 支付状态
Metadata *OrderDetail `gorm:"metadata,type:json" json:"metadata"` //
Ctime *time.Time `gorm:"default:'0000-00-00 00:00:00';" json:"ctime"` //
Utime *time.Time `gorm:"default:'0000-00-00 00:00:00';" json:"utime"` //
IsDel *int64 `gorm:"default:0;" json:"is_del"` // 是否删除0=否1=是
}
// 订单详情
type OrderDetail struct {
DeliveryAddress *OrderAddress `json:"delivery_address"` // 收货地址