This commit is contained in:
zhaoxiaorong
2025-02-07 17:08:55 +08:00
parent fd62c5cddb
commit 58139791f3
8 changed files with 220 additions and 6 deletions

16
infra/new.go Normal file
View File

@@ -0,0 +1,16 @@
package infra
import (
"git.apinb.com/bsm-sdk/core/cache/redis"
"gorm.io/gorm"
)
var (
DB *gorm.DB
RedisCache *redis.RedisClient
)
func New(db *gorm.DB, redisCache *redis.RedisClient) {
DB = db
RedisCache = redisCache
}