Detect theme and exercice language at runtime (not stored)
This commit is contained in:
parent
99cc79421f
commit
aa0e7406c1
17 changed files with 99 additions and 42 deletions
|
|
@ -20,9 +20,10 @@ var ExerciceCurrentCoefficient = 1.0
|
|||
|
||||
// Exercice represents a challenge inside a Theme.
|
||||
type Exercice struct {
|
||||
Id int64 `json:"id"`
|
||||
IdTheme int64 `json:"id_theme"`
|
||||
Title string `json:"title"`
|
||||
Id int64 `json:"id"`
|
||||
IdTheme int64 `json:"id_theme"`
|
||||
Language string `json:"lang,omitempty"`
|
||||
Title string `json:"title"`
|
||||
// WIP indicates if the exercice is in development or not
|
||||
WIP bool `json:"wip"`
|
||||
// URLid is used to reference the challenge from the URL path
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import ()
|
|||
// Theme represents a group of challenges, to display to players
|
||||
type Theme struct {
|
||||
Id int64 `json:"id"`
|
||||
Language string `json:"lang,omitempty"`
|
||||
Name string `json:"name"`
|
||||
URLId string `json:"urlid"`
|
||||
Path string `json:"path"`
|
||||
|
|
|
|||
Reference in a new issue