Refactor code

pull/131/head
wenxu12345 3 years ago
parent b6bd2687d2
commit 9b76407193

@ -53,13 +53,13 @@ func initMysqlDB() {
log.NewInfo("open db ok ", dsn)
//db.AutoMigrate(&Friend{},
// &FriendRequest{},
// &Group{},
// &GroupMember{},
// &GroupRequest{},
// &User{},
// &Black{})
db.AutoMigrate(&Friend{},
&FriendRequest{},
&Group{},
&GroupMember{},
&GroupRequest{},
&User{},
&Black{})
if !db.HasTable(&Friend{}) {
log.NewInfo("CreateTable Friend")

Loading…
Cancel
Save