修复 「1.2.2 用户管理-用户列表勾选单一用户会全选 」 close #216
This commit is contained in:
19
server/env/env.go
vendored
Normal file
19
server/env/env.go
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
package env
|
||||
|
||||
import "gorm.io/gorm"
|
||||
|
||||
var env *Env
|
||||
|
||||
type Env struct {
|
||||
db *gorm.DB
|
||||
}
|
||||
|
||||
func init() {
|
||||
env = &Env{
|
||||
db: setupDB(),
|
||||
}
|
||||
}
|
||||
|
||||
func GetDB() *gorm.DB {
|
||||
return env.db
|
||||
}
|
Reference in New Issue
Block a user