feat:优化信息

This commit is contained in:
henry
2021-11-23 09:46:36 +08:00
parent ee5a4b9cf6
commit ea4de49ae5

View File

@ -6,7 +6,6 @@ import (
"ArmedPolice/lib"
"ArmedPolice/serve/orm"
"ArmedPolice/utils"
"fmt"
)
type synchronized struct {
@ -60,7 +59,7 @@ func initModel() {
function := func(synchronized ...*synchronized) {
for _, v := range synchronized {
fmt.Println(db.Migrator().HasTable(v.iModel))
if !db.Migrator().HasTable(v.iModel) {
_ = db.Migrator().CreateTable(v.iModel)