feat: Implement system setup functionality

This commit is contained in:
CaIon
2025-04-03 18:57:15 +08:00
parent 1de0d9123b
commit f33ebc8e2c
11 changed files with 490 additions and 1 deletions
+16
View File
@@ -0,0 +1,16 @@
package model
type Setup struct {
ID uint `json:"id" gorm:"primaryKey"`
Version string `json:"version" gorm:"type:varchar(50);not null"`
InitializedAt int64 `json:"initialized_at" gorm:"type:bigint;not null"`
}
func GetSetup() *Setup {
var setup Setup
err := DB.First(&setup).Error
if err != nil {
return nil
}
return &setup
}