Pull Proclamations & Categories from API and store them in the database

This commit is contained in:
NeilClack
2026-03-23 17:35:52 -05:00
parent 17c088cc2f
commit 8d23841391
8 changed files with 161 additions and 54 deletions
+1 -1
View File
@@ -41,7 +41,7 @@ func Connect(dbpath string) (*gorm.DB, error) {
// Migrate the database schema
func Migrate(db *gorm.DB) error {
// Pass all models to be migrated to this function call.
if err := db.AutoMigrate(&AppConfig{}, &Log{}, &Proclamation{}); err != nil {
if err := db.AutoMigrate(&AppConfig{}, &Log{}, &Proclamation{}, &ProclamationCategory{}); err != nil {
return err
}
return nil