系统房奖品价值缺失
This commit is contained in:
parent
1d89a8c36e
commit
0f1f8a03c2
|
@ -7,8 +7,8 @@ import (
|
|||
|
||||
"go.mongodb.org/mongo-driver/mongo"
|
||||
|
||||
"mongo.games.com/game/common"
|
||||
mon "mongo.games.com/game/mongo"
|
||||
"mongo.games.com/game/util/viperx"
|
||||
"mongo.games.com/goserver/core/logger"
|
||||
)
|
||||
|
||||
|
@ -19,7 +19,7 @@ type ServiceContext struct {
|
|||
|
||||
func NewServiceContext() *ServiceContext {
|
||||
|
||||
vp := common.GetViper("mgo", "json")
|
||||
vp := viperx.GetViper("mgo", "json")
|
||||
// mongo初始化
|
||||
conf := &mon.Config{}
|
||||
err := vp.Unmarshal(conf)
|
||||
|
|
|
@ -18,7 +18,7 @@ import (
|
|||
"mongo.games.com/game/statistics/static"
|
||||
"mongo.games.com/game/statistics/syn"
|
||||
"mongo.games.com/game/statistics/tools"
|
||||
"mongo.games.com/game/util"
|
||||
"mongo.games.com/game/util/viperx"
|
||||
)
|
||||
|
||||
var VP *viper.Viper
|
||||
|
@ -95,9 +95,9 @@ func DoTickPlatform(ctx context.Context, wg *sync.WaitGroup, duration time.Durat
|
|||
}
|
||||
|
||||
func main() {
|
||||
VP = util.GetViper("config", "yaml")
|
||||
VP = viperx.GetViper("config", "yaml")
|
||||
// mongo
|
||||
vp := util.GetViper("mongo", "yaml")
|
||||
vp := viperx.GetViper("mongo", "yaml")
|
||||
// mongo初始化
|
||||
conf := &mongo.Config{}
|
||||
err := vp.Unmarshal(conf)
|
||||
|
@ -108,7 +108,7 @@ func main() {
|
|||
defer mongo.Close()
|
||||
|
||||
// mysql
|
||||
vp = util.GetViper("mysql", "yaml")
|
||||
vp = viperx.GetViper("mysql", "yaml")
|
||||
myConf := &mysql.Config{}
|
||||
err = vp.Unmarshal(myConf)
|
||||
if err != nil {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package util
|
||||
package viperx
|
||||
|
||||
import (
|
||||
"fmt"
|
|
@ -300,6 +300,8 @@ func (c *CustomRoomMgr) UpdateCreate(plt string, configId int32, mustCreate bool
|
|||
RoomConfigId: roomConfig.GetId(),
|
||||
CostType: 1,
|
||||
Voice: cfg.GetVoice(),
|
||||
Price: roomConfig.GetPrice(),
|
||||
ImageURL: roomConfig.GetImageURI(),
|
||||
},
|
||||
RoomConfigSystem: cfg,
|
||||
IsRecruit: true,
|
||||
|
|
Loading…
Reference in New Issue