优化 model json 格式化注释
This commit is contained in:
@@ -7,12 +7,12 @@ import (
|
||||
// Announcement 公告表
|
||||
type Announcement struct {
|
||||
core.Model
|
||||
Title string `json:"title" gorm:"column:title"` // 公告标题
|
||||
Content *string `json:"content" gorm:"column:content"` // 公告内容
|
||||
Type AnnouncementType `json:"type" gorm:"column:type"` // 公告类型:1-普通公告
|
||||
Pin bool `json:"pin" gorm:"column:pin"` // 是否置顶
|
||||
Status AnnouncementStatus `json:"status" gorm:"column:status"` // 公告状态:0-禁用,1-正常
|
||||
Sort int32 `json:"sort" gorm:"column:sort"` // 公告排序
|
||||
Title string `json:"title" gorm:"column:title"` // 公告标题
|
||||
Content *string `json:"content,omitempty" gorm:"column:content"` // 公告内容
|
||||
Type AnnouncementType `json:"type" gorm:"column:type"` // 公告类型:1-普通公告
|
||||
Pin bool `json:"pin" gorm:"column:pin"` // 是否置顶
|
||||
Status AnnouncementStatus `json:"status" gorm:"column:status"` // 公告状态:0-禁用,1-正常
|
||||
Sort int32 `json:"sort" gorm:"column:sort"` // 公告排序
|
||||
}
|
||||
|
||||
// AnnouncementType 公告类型枚举
|
||||
|
||||
Reference in New Issue
Block a user