bindbox-game/internal/repository/mysql/model/ops_shipping_stats.gen.go
邹方成 6ee627139c
Some checks failed
Build docker and publish / linux (1.24.5) (push) Failing after 40s
feat: 新增支付测试小程序与微信支付集成
feat(pay): 添加支付API基础结构
feat(miniapp): 创建支付测试小程序页面与配置
feat(wechatpay): 配置微信支付参数与证书
fix(guild): 修复成员列表查询条件
docs: 更新代码规范文档与需求文档
style: 统一前后端枚举显示与注释格式
refactor(admin): 重构用户奖励发放接口参数处理
test(title): 添加称号效果参数验证测试
2025-11-17 00:42:08 +08:00

41 lines
5.9 KiB
Go
Raw Permalink 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.

// Code generated by gorm.io/gen. DO NOT EDIT.
// Code generated by gorm.io/gen. DO NOT EDIT.
// Code generated by gorm.io/gen. DO NOT EDIT.
package model
import (
"time"
)
const TableNameOpsShippingStats = "ops_shipping_stats"
// OpsShippingStats 运营发货统计(离线明细表)
type OpsShippingStats struct {
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:主键ID" json:"id"` // 主键ID
ShippedAt time.Time `gorm:"column:shipped_at;not null;comment:发货时间来源shipping_records.shipped_at" json:"shipped_at"` // 发货时间来源shipping_records.shipped_at
ProductID int64 `gorm:"column:product_id;comment:商品ID优先取 shipping_records.product_id否则取 order_items.product_id" json:"product_id"` // 商品ID优先取 shipping_records.product_id否则取 order_items.product_id
ProductName string `gorm:"column:product_name;not null;comment:产品名称(优先取 order_items.title 快照,否则取 products.name" json:"product_name"` // 产品名称(优先取 order_items.title 快照,否则取 products.name
ProductPriceCents int64 `gorm:"column:product_price_cents;not null;comment:产品价格(单位分;优先取 shipping_records.price其次 order_items.price最后 products.price" json:"product_price_cents"` // 产品价格(单位分;优先取 shipping_records.price其次 order_items.price最后 products.price
ShippedQty int64 `gorm:"column:shipped_qty;not null;comment:发货数量来源shipping_records.quantity" json:"shipped_qty"` // 发货数量来源shipping_records.quantity
UserID int64 `gorm:"column:user_id;not null;comment:收件用户ID来源user_addresses.user_id" json:"user_id"` // 收件用户ID来源user_addresses.user_id
UserName string `gorm:"column:user_name;not null;comment:收件人姓名来源user_addresses.name" json:"user_name"` // 收件人姓名来源user_addresses.name
UserAddressText string `gorm:"column:user_address_text;not null;comment:收件人地址(拼接 province/city/district/address" json:"user_address_text"` // 收件人地址(拼接 province/city/district/address
ExpressCode string `gorm:"column:express_code;comment:快递公司编码来源shipping_records.express_code" json:"express_code"` // 快递公司编码来源shipping_records.express_code
ExpressNo string `gorm:"column:express_no;comment:物流单号来源shipping_records.express_no" json:"express_no"` // 物流单号来源shipping_records.express_no
OrderID int64 `gorm:"column:order_id;comment:订单ID来源shipping_records.order_id" json:"order_id"` // 订单ID来源shipping_records.order_id
OrderNo string `gorm:"column:order_no;comment:订单号来源orders.order_no" json:"order_no"` // 订单号来源orders.order_no
OrderQty int64 `gorm:"column:order_qty;comment:下单数量(订单维度总件数,聚合 order_items.quantity" json:"order_qty"` // 下单数量(订单维度总件数,聚合 order_items.quantity
OrderAmountCents int64 `gorm:"column:order_amount_cents;comment:下单金额(单位分;订单实付金额 orders.actual_amount" json:"order_amount_cents"` // 下单金额(单位分;订单实付金额 orders.actual_amount
ProfitLossCents int64 `gorm:"column:profit_loss_cents;comment:盈亏金额(单位分;行价格×发货数量 订单实付金额;可按运营口径调整)" json:"profit_loss_cents"` // 盈亏金额(单位分;行价格×发货数量 订单实付金额;可按运营口径调整)
OrderSourceType int32 `gorm:"column:order_source_type;comment:下单来源类型码1商城直购 2抽奖票据 3其他来源orders.source_type" json:"order_source_type"` // 下单来源类型码1商城直购 2抽奖票据 3其他来源orders.source_type
OrderSourceText string `gorm:"column:order_source_text;comment:下单来源中文(由 order_source_type 映射:商城直购/抽奖票据/其他/未知)" json:"order_source_text"` // 下单来源中文(由 order_source_type 映射:商城直购/抽奖票据/其他/未知)
Payer string `gorm:"column:payer;comment:垫付人(当前业务未存;建议新增 shipping_records.payer 或在 remark 规范写入并解析)" json:"payer"` // 垫付人(当前业务未存;建议新增 shipping_records.payer 或在 remark 规范写入并解析)
CreatedAt time.Time `gorm:"column:created_at;not null;default:CURRENT_TIMESTAMP;comment:统计入库时间" json:"created_at"` // 统计入库时间
}
// TableName OpsShippingStats's table name
func (*OpsShippingStats) TableName() string {
return TableNameOpsShippingStats
}