feat: initial commit

This commit is contained in:
2025-06-16 00:07:03 +02:00
parent d93ed20869
commit a6d5cb50f2
26 changed files with 10870 additions and 156 deletions

View File

@ -1,6 +1,7 @@
package store
import (
"fmt"
"time"
"gorm.io/datatypes"
@ -64,3 +65,16 @@ type QuizEntry struct {
Level uint `gorm:"index"`
Anecdote string
}
func DifficultyLevel(level uint) string {
switch level {
case 0:
return "Débutant"
case 1:
return "Confirmé"
case 2:
return "Expert"
default:
return fmt.Sprintf("Hors catégorie (%d)", level)
}
}