From a039684fb5e2bf7953db3944097ce35b2c1141ac Mon Sep 17 00:00:00 2001 From: yangduo Date: Tue, 16 Jul 2024 18:07:24 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/adminserver/model/system/mallitem.go | 36 ++++++++++----------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/server/adminserver/model/system/mallitem.go b/server/adminserver/model/system/mallitem.go index 98c94a5b..eec273e2 100644 --- a/server/adminserver/model/system/mallitem.go +++ b/server/adminserver/model/system/mallitem.go @@ -6,23 +6,23 @@ import ( ) type MallItem struct { - Idx int64 `json:"idx"` - Order_id string `gorm:"comment:订单id" json:"order_id"` - Order_type int `gorm:"comment:1:英雄 2:芯片 3:碎片 4:宝箱" json:"order_type"` - Seller string `gorm:"comment:seller" json:"seller"` - Seller_address string `gorm:"comment:seller_address" json:"seller_address"` - Goods_uniid string `gorm:"comment:物品id" json:"goods_uniid"` - Item_id int `gorm:"comment:道具id" json:"item_id"` - Item_num int64 `gorm:"comment:物品数量" json:"item_num"` - Price int64 `gorm:"comment:价格" json:"price"` - Status int `gorm:"comment:status" json:"status"` - Buyer string `gorm:"comment:购买成功者" json:"buyer"` - Buy_ok_time int `gorm:"comment:购买成功时间" json:"buy_ok_time"` - Last_modify_price_time int `gorm:"comment:最后一次修改价格时间" json:"last_modify_price_time"` - Createtime int `gorm:"comment:创建时间" json:"createtime"` - Modifytime int `gorm:"comment:修改时间" json:"modifytime"` - Order1 int `gorm:"comment:品质排序" json:"order1"` - Unit_price int `gorm:"comment:单价" json:"unit_price"` + Idx int64 `json:"idx"` + Order_id string `gorm:"comment:订单id" json:"order_id"` + Order_type int `gorm:"comment:1:英雄 2:芯片 3:碎片 4:宝箱" json:"order_type"` + Seller string `gorm:"comment:seller" json:"seller"` + Seller_address string `gorm:"comment:seller_address" json:"seller_address"` + Goods_uniid string `gorm:"comment:物品id" json:"goods_uniid"` + Item_id int `gorm:"comment:道具id" json:"item_id"` + Item_num int64 `gorm:"comment:物品数量" json:"item_num"` + Price int64 `gorm:"comment:价格" json:"price"` + Status int `gorm:"comment:status" json:"status"` + Buyer string `gorm:"comment:购买成功者" json:"buyer"` + Buy_ok_time int `gorm:"comment:购买成功时间" json:"buy_ok_time"` + Last_modify_price_time int `gorm:"comment:最后一次修改价格时间" json:"last_modify_price_time"` + Createtime int `gorm:"comment:创建时间" json:"createtime"` + Modifytime int `gorm:"comment:修改时间" json:"modifytime"` + Order1 int `gorm:"comment:品质排序" json:"order1"` + Unit_price float32 `gorm:"comment:单价" json:"unit_price"` } func (mi *MallItem) TableName() string { @@ -46,5 +46,5 @@ func (mi *MallItem) LoadFromDs(ds *f5.DataSet) { mi.Createtime = q5.ToInt(ds.GetByName("createtime")) mi.Modifytime = q5.ToInt(ds.GetByName("modifytime")) mi.Order1 = q5.ToInt(ds.GetByName("order1")) - mi.Unit_price = q5.ToInt(ds.GetByName("unit_price")) + mi.Unit_price = q5.ToFloat32(ds.GetByName("unit_price")) }