From 57ef70911bc4bafa6d88ed39a9e2adc3afc895da Mon Sep 17 00:00:00 2001 From: xinian Date: Mon, 23 Feb 2026 02:41:31 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=B8=BA=E9=87=91=E8=B1=86=E6=B6=88?= =?UTF-8?q?=E8=B4=B9=E8=AE=B0=E5=BD=95=E6=B7=BB=E5=8A=A0=E5=B9=B4=E4=BB=BD?= =?UTF-8?q?=E5=92=8C=E6=97=B6=E9=97=B4=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/player/model/GoldBeanConsume.go | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/modules/player/model/GoldBeanConsume.go b/modules/player/model/GoldBeanConsume.go index 7b300be0..510cfba0 100644 --- a/modules/player/model/GoldBeanConsume.go +++ b/modules/player/model/GoldBeanConsume.go @@ -14,9 +14,14 @@ const ( type GoldBeanConsume struct { Base - UID uint32 `gorm:"not null;default:0;index;comment:'玩家唯一ID,关联玩家表主键'" json:"uid" description:"玩家ID"` - ConsumeNum uint32 `gorm:"not null;default:0;comment:'金豆消费数量(非负数)'" json:"consume_num" description:"消费金豆数量"` - BizID uint32 `gorm:"not null;default:0;comment:'关联业务ID(如道具ID/扭蛋池ID,无则填0)'" json:"biz_id" description:"关联业务ID"` + UID uint32 `gorm:"not null;default:0;index;comment:'玩家唯一ID,关联玩家表主键'" json:"uid" description:"玩家ID"` + ConsumeNum uint32 `gorm:"not null;default:0;comment:'金豆消费数量(非负数)'" json:"consume_num" description:"消费金豆数量"` + BizID uint32 `gorm:"not null;default:0;comment:'关联业务ID(如道具ID/扭蛋池ID,无则填0)'" json:"biz_id" description:"关联业务ID"` + ///消费年份 + Year uint32 `gorm:"not null;default:0;comment:'消费年份'" json:"year" description:"消费年份"` + //消费时间,由月-周-日组成,判断金豆物品的购买重置周期 + Consume []uint32 `gorm:"type:jsonb; comment:'消费时间'" json:"consume" description:"消费时间"` + BeforeBalance uint32 `gorm:"not null;default:0;comment:'消费前金豆余额'" json:"before_balance" description:"消费前余额"` }