47 lines
1.1 KiB
Go
47 lines
1.1 KiB
Go
package mt
|
|
|
|
import (
|
|
"f5"
|
|
)
|
|
|
|
type table struct {
|
|
AdminCluster *AdminClusterTable
|
|
GameDb *GameDbTable
|
|
FriendDb *FriendDbTable
|
|
Config *ConfigTable
|
|
RankSeason *RankSeasonTable
|
|
HashRateCommon *HashRateCommonTable
|
|
}
|
|
|
|
var Table = f5.New(func(this *table) {
|
|
this.AdminCluster = f5.New(func(this *AdminClusterTable) {
|
|
this.FileName = "../config/adminserver.cluster.json"
|
|
this.PrimKey = "instance_id"
|
|
})
|
|
|
|
this.GameDb = f5.New(func(this *GameDbTable) {
|
|
this.FileName = "../config/gamedb.mysql.json"
|
|
this.PrimKey = ""
|
|
})
|
|
|
|
this.FriendDb = f5.New(func(this *FriendDbTable) {
|
|
this.FileName = "../config/frienddb.mysql.json"
|
|
this.PrimKey = ""
|
|
})
|
|
|
|
this.Config = f5.New(func(this *ConfigTable) {
|
|
this.FileName = "../config/config.json"
|
|
this.PrimKey = ""
|
|
})
|
|
|
|
this.RankSeason = f5.New(func(this *RankSeasonTable) {
|
|
this.FileName = "../res/rankSeason@rankSeason.json"
|
|
this.PrimKey = "id"
|
|
})
|
|
|
|
this.HashRateCommon = f5.New(func(this *HashRateCommonTable) {
|
|
this.FileName = "../res/HashrateCommon@HashrateCommon.json"
|
|
this.PrimKey = "id"
|
|
})
|
|
})
|