First implementation of fetching collections of book managed by user

This commit is contained in:
2026-04-02 16:23:22 +02:00
parent acdc3972bd
commit a280647575
18 changed files with 377 additions and 41 deletions

View File

@@ -22,6 +22,7 @@ func Initdb(databasePath string, demoDataPath string) *gorm.DB {
db.AutoMigrate(&model.User{})
db.AutoMigrate(&model.UserBook{})
db.AutoMigrate(&model.StaticFile{})
db.AutoMigrate(&model.Collection{})
var book model.Book
queryResult := db.Limit(1).Find(&book)
if queryResult.RowsAffected == 0 && demoDataPath != "" {