feat: 默认注册表增加 info表和图库分类表
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
|||||||
adapter "github.com/casbin/gorm-adapter/v3"
|
adapter "github.com/casbin/gorm-adapter/v3"
|
||||||
"github.com/flipped-aurora/gin-vue-admin/server/model/example"
|
"github.com/flipped-aurora/gin-vue-admin/server/model/example"
|
||||||
sysModel "github.com/flipped-aurora/gin-vue-admin/server/model/system"
|
sysModel "github.com/flipped-aurora/gin-vue-admin/server/model/system"
|
||||||
|
"github.com/flipped-aurora/gin-vue-admin/server/plugin/announcement/model"
|
||||||
"github.com/flipped-aurora/gin-vue-admin/server/service/system"
|
"github.com/flipped-aurora/gin-vue-admin/server/service/system"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
)
|
)
|
||||||
@@ -59,6 +60,9 @@ func (e *ensureTables) MigrateTable(ctx context.Context) (context.Context, error
|
|||||||
example.ExaCustomer{},
|
example.ExaCustomer{},
|
||||||
example.ExaFileChunk{},
|
example.ExaFileChunk{},
|
||||||
example.ExaFileUploadAndDownload{},
|
example.ExaFileUploadAndDownload{},
|
||||||
|
example.ExaAttachmentCategory{},
|
||||||
|
|
||||||
|
model.Info{},
|
||||||
}
|
}
|
||||||
for _, t := range tables {
|
for _, t := range tables {
|
||||||
_ = db.AutoMigrate(&t)
|
_ = db.AutoMigrate(&t)
|
||||||
@@ -97,6 +101,9 @@ func (e *ensureTables) TableCreated(ctx context.Context) bool {
|
|||||||
example.ExaCustomer{},
|
example.ExaCustomer{},
|
||||||
example.ExaFileChunk{},
|
example.ExaFileChunk{},
|
||||||
example.ExaFileUploadAndDownload{},
|
example.ExaFileUploadAndDownload{},
|
||||||
|
example.ExaAttachmentCategory{},
|
||||||
|
|
||||||
|
model.Info{},
|
||||||
}
|
}
|
||||||
yes := true
|
yes := true
|
||||||
for _, t := range tables {
|
for _, t := range tables {
|
||||||
|
Reference in New Issue
Block a user