瀏覽代碼

转链

master
huangjiajun 5 月之前
父節點
當前提交
d5802f87f7
共有 1 個檔案被更改,包括 9 行新增0 行删除
  1. +9
    -0
      chain_transfer/turn_chain.go

+ 9
- 0
chain_transfer/turn_chain.go 查看文件

@@ -5,6 +5,7 @@ import (
"code.fnuoos.com/go_rely_warehouse/zyos_go_third_party_api.git/db"
"code.fnuoos.com/go_rely_warehouse/zyos_go_third_party_api.git/md"
zhios_third_party_utils "code.fnuoos.com/go_rely_warehouse/zyos_go_third_party_api.git/utils"
"code.fnuoos.com/go_rely_warehouse/zyos_go_third_party_api.git/utils/cache"
"fmt"
"github.com/mvdan/xurls"
"regexp"
@@ -13,6 +14,14 @@ import (
"xorm.io/xorm"
)

func Init(redisAddr string) (err error) {
if redisAddr != "" {
cache.NewRedis(redisAddr)
}
_, err = cache.SelectDb(md.RedisDataBase)
return
}

func TurnChain(eg *xorm.Engine, officialEg, zhimengEg *xorm.Engine, args map[string]string) md.TCPrase {
dbName := args["master_id"]
var tcPrase md.TCPrase


Loading…
取消
儲存