sys_stake_period_job.go 1.5 KB

12345678910111213141516171819202122232425262728
  1. package app
  2. // 引入关联包
  3. import (
  4. "github.com/shopspring/decimal"
  5. )
  6. type SysStakePeriodJob struct {
  7. Id int64 `json:"id" gorm:"column:id;type:bigint;comment:id;primarykey;NOT NULL"`
  8. CreatedAt int64 `json:"createdAt" gorm:"column:created_at;type:bigint;comment:创建时间"`
  9. UpdatedAt int64 `json:"updatedAt" gorm:"column:updated_at;type:bigint;comment:更新时间"`
  10. PeriodNo string `json:"periodNo" gorm:"column:period_no;type:varchar(64);comment:期编号;index;unique:idx_sys_stake_period_job_period_no"`
  11. JobState string `json:"jobState" gorm:"column:job_state;type:varchar(32);comment:状态:running 进行中 success 成功 failure 失败"`
  12. Price decimal.Decimal `json:"price" gorm:"column:price;type:decimal(25,8);comment:当期单价"`
  13. StaticSymbolProfit decimal.Decimal `json:"staticSymbolProfit" gorm:"column:static_symbol_profit;type:decimal(25,8);comment:期静态币总收益"`
  14. StaticUsdProfit decimal.Decimal `json:"staticUsdProfit" gorm:"column:static_usd_profit;type:decimal(25,8);comment:期USD总收益"`
  15. LevelProfit decimal.Decimal `json:"levelProfit" gorm:"column:level_profit;type:decimal(25,8);comment:动态等级奖励"`
  16. LevelProfitIsCal bool `json:"levelProfitIsCal" gorm:"column:level_profit_is_cal;type:tinyint(1);comment:动态等级奖励是否计算完成"`
  17. Desc string `json:"desc" gorm:"column:desc;type:text;comment:错误信息"`
  18. }
  19. func (*SysStakePeriodJob) TableName() string {
  20. return "sys_stake_period_job"
  21. }
  22. func NewSysStakePeriodJob() *SysStakePeriodJob {
  23. return &SysStakePeriodJob{}
  24. }