daShangDao_psiServer/models/shipping_order.go
2026-06-27 10:51:03 +08:00

27 lines
1.6 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package models
// ShippingOrder 发货单主表
type ShippingOrder struct {
ID int64 `json:"id" gorm:"primarykey;comment:主键ID"`
ShippingNo string `json:"shipping_no" gorm:"size:64;not null;default:'';uniqueIndex;comment:发货单号"`
CustomerID int64 `json:"customer_id" gorm:"not null;default:0;index;comment:客户ID"`
ShopId int64 `json:"shop_id" gorm:"type:bigint(20);default:0;comment:店铺ID"`
Status int8 `json:"status" gorm:"not null;default:1;index;comment:状态1=待发货 2=已发货 3=已签收 4=已取消"`
ShippingTime *int64 `json:"shipping_time" gorm:"type:bigint;comment:发货时间(时间戳秒)"`
ExpectedArriveTime *int64 `json:"expected_arrive_time" gorm:"type:bigint;comment:预计到达时间(时间戳秒)"`
ActualArriveTime *int64 `json:"actual_arrive_time" gorm:"type:bigint;comment:实际签收时间(时间戳秒)"`
Operator string `json:"operator" gorm:"size:50;comment:操作人"`
CreatedAt int64 `json:"created_at" gorm:"type:bigint;not null;default:0;comment:创建时间(时间戳秒)"`
UpdatedAt *int64 `json:"updated_at" gorm:"type:bigint;comment:更新时间(时间戳秒)"`
IsDel int8 `json:"is_del" gorm:"type:tinyint(1);not null;default:0;comment:逻辑删除标记(0:未删除,1:已删除)"`
Remark string `json:"remark" gorm:"size:500;comment:备注"`
}
func (ShippingOrder) TableName() string {
return "shipping_order"
}
func (ShippingOrder) TableOptions() string {
return "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='发货单主表'"
}