mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-12 13:05:58 +08:00
cms
This commit is contained in:
@@ -78,7 +78,7 @@ func initMysqlDB() {
|
||||
&GroupMember{},
|
||||
&GroupRequest{},
|
||||
&User{},
|
||||
&Black{}, &ChatLog{}, &Register{}, &Conversation{}, &AppVersion{}, &Department{}, &BlackList{}, &IpLimit{}, &UserIpLimit{}, &Invitation{})
|
||||
&Black{}, &ChatLog{}, &Register{}, &Conversation{}, &AppVersion{}, &Department{}, &BlackList{}, &IpLimit{}, &UserIpLimit{}, &Invitation{}, &RegisterAddFriend{})
|
||||
db.Set("gorm:table_options", "CHARSET=utf8")
|
||||
db.Set("gorm:table_options", "collation=utf8_unicode_ci")
|
||||
|
||||
@@ -154,6 +154,11 @@ func initMysqlDB() {
|
||||
fmt.Println("CreateTable UserIpLimit")
|
||||
db.Migrator().CreateTable(&UserIpLimit{})
|
||||
}
|
||||
|
||||
if !db.Migrator().HasTable(&RegisterAddFriend{}) {
|
||||
fmt.Println("CreateTable RegisterAddFriend")
|
||||
db.Migrator().CreateTable(&RegisterAddFriend{})
|
||||
}
|
||||
DB.MysqlDB.db = db
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user