probo/models/quiz.go

12 lines
296 B
Go
Raw Normal View History

2022-06-23 11:25:35 +02:00
package models
type Quiz struct {
2023-09-22 10:29:10 +02:00
Meta
2023-10-28 20:50:06 +02:00
2023-07-04 18:05:19 +02:00
Hash string `json:"hash"`
2023-10-28 20:50:06 +02:00
Question *Question `json:"question" gorm:"foreignKey:ID"`
Answers []*Answer `json:"answers" gorm:"many2many:quiz_answers"`
Correct *Answer `json:"correct" gorm:"foreignKey:ID"`
2023-07-04 18:05:19 +02:00
Type int `json:"type"`
2022-06-23 11:25:35 +02:00
}