package dao type AnswerCreate struct { Id int64 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT;comment:ID" json:"id"` Question string `gorm:"column:question;type:text;comment:问题;NOT NULL" json:"question"` Explain string `gorm:"column:explain;type:text;comment:说明;NOT NULL" json:"explain"` Right string `gorm:"column:right;type:varchar(10);comment:正确答案;NOT NULL" json:"right"` Answers string `gorm:"column:answers;type:text;comment:选择答案;NOT NULL" json:"answers"` AdminId int64 `gorm:"column:admin_id;type:int(11)" json:"admin_id"` AdminName string `gorm:"column:admin_name;type:varchar(255)" json:"admin_name"` } type AnswerInfo struct { Id int64 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT;comment:ID" json:"id"` Question string `gorm:"column:question;type:text;comment:问题;NOT NULL" json:"question"` Explain string `gorm:"column:explain;type:text;comment:说明;NOT NULL" json:"explain"` Status int32 `gorm:"column:status;type:tinyint(1);default:1;comment:状态,1为正常,2为禁用;NOT NULL" json:"status"` Right string `gorm:"column:right;type:varchar(10);comment:正确答案;NOT NULL" json:"right"` Answers string `gorm:"column:answers;type:text;comment:选择答案;NOT NULL" json:"answers"` } type AnswerStatus struct { Id int64 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT;comment:ID" json:"id"` Reason string `gorm:"column:reason;type:varchar(255);comment:禁用原因" json:"reason"` Status int32 `gorm:"column:status;type:tinyint(1);default:1;comment:状态,1为正常,2为禁用;NOT NULL" json:"status"` AdminId int64 `gorm:"column:admin_id;type:int(11)" json:"admin_id"` AdminName string `gorm:"column:admin_name;type:varchar(255)" json:"admin_name"` }