mirror of
https://gitee.com/shikong-sk/gofiber-study
synced 2025-02-25 00:02:17 +08:00
21 lines
750 B
Go
21 lines
750 B
Go
package models
|
|
|
|
import (
|
|
"gofiber.study.skcks.cn/common/time"
|
|
)
|
|
|
|
type Topical struct {
|
|
Id string `xorm:"not null pk VARCHAR(32)" json:"id"`
|
|
Active bool `xorm:"not null index BIT(1)" json:"active"`
|
|
Content string `xorm:"not null index LONGTEXT(4294967295)" json:"content"`
|
|
CreateTime time.Time `xorm:"not null index DATETIME(6) created" json:"createTime"`
|
|
ModifyTime time.Time `xorm:"not null index DATETIME(6) updated" json:"modifyTime"`
|
|
ModifyTimes int64 `xorm:"not null index BIGINT" json:"modifyTimes"`
|
|
Title string `xorm:"not null VARCHAR(255)" json:"title"`
|
|
UserId string `xorm:"not null index VARCHAR(32)" json:"userId"`
|
|
}
|
|
|
|
func (m *Topical) TableName() string {
|
|
return "topical"
|
|
}
|