mirror of
https://github.com/Wei-Shaw/sub2api.git
synced 2026-11-29 15:35:11 +00:00
refactor: 调整项目结构为单向依赖
This commit is contained in:
1 parent
b3463769dc
commit
e5a77853b0
98 files changed
+5503
-3352
No files matched your search
@@ -0,0 +1,20 @@
|
||||
package repository
|
||||
|
||||
import "gorm.io/gorm"
|
||||
|
||||
// AutoMigrate runs schema migrations for all repository persistence models.
|
||||
// Persistence models are defined within individual `*_repo.go` files.
|
||||
func AutoMigrate(db *gorm.DB) error {
|
||||
return db.AutoMigrate(
|
||||
&userModel{},
|
||||
&apiKeyModel{},
|
||||
&groupModel{},
|
||||
&accountModel{},
|
||||
&accountGroupModel{},
|
||||
&proxyModel{},
|
||||
&redeemCodeModel{},
|
||||
&usageLogModel{},
|
||||
&settingModel{},
|
||||
&userSubscriptionModel{},
|
||||
)
|
||||
}
|
||||
Reference in new issue
Block a user