Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Question ¶
type Question struct { base.DefaultModel Type int8 `gorm:"NOT NULL;comment:题型"` Title string `gorm:"size:50;NOT NULL;comment:标题"` Content string `gorm:"size:1000;NOT NULL;comment:内容"` Tags pq.StringArray `gorm:"type:varchar(10)[];comment:标签"` Answer string `gorm:"size:1000;NOT NULL;comment:答案"` Difficulty string `gorm:"size:10;NOT NULL;comment:难度"` }
func NewQuestion ¶
func NewQuestion() *Question
func NewQuestionFromPB ¶
func NewQuestionFromPB(in *pb.CreateQuestionRequest) *Question
Click to show internal directories.
Click to hide internal directories.