mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-08-16 17:22:12 +08:00
Error code standardization
This commit is contained in:
parent
1797267a6b
commit
29c1bb86d8
@ -5,9 +5,21 @@ import (
|
|||||||
"Open_IM/pkg/utils"
|
"Open_IM/pkg/utils"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"gorm.io/gorm"
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
var (
|
||||||
|
BlackListDB *gorm.DB
|
||||||
|
UserDB *gorm.DB
|
||||||
|
)
|
||||||
|
|
||||||
|
type BlackList struct {
|
||||||
|
UserId string `gorm:"column:uid"`
|
||||||
|
BeginDisableTime time.Time `gorm:"column:begin_disable_time"`
|
||||||
|
EndDisableTime time.Time `gorm:"column:end_disable_time"`
|
||||||
|
}
|
||||||
|
|
||||||
func UserRegister(user User) error {
|
func UserRegister(user User) error {
|
||||||
user.CreateTime = time.Now()
|
user.CreateTime = time.Now()
|
||||||
if user.AppMangerLevel == 0 {
|
if user.AppMangerLevel == 0 {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user