package model

//
//var (
//	JackPotLogDBName        = "log"
//	JackPotLogCollName      = "log_jackpotlog"
//	TopicProbeJackPotLogAck = "ack_jackpotlog"
//)
//
//type JackPot struct {
//	Val int64
//	Ts  int64
//}
//type JackPotLog struct {
//	LogId      bson.ObjectId `bson:"_id"`
//	Platform   string        //平台
//	GameFreeId int32
//	WaterVal   []byte
//	JkVal1     []byte
//	JkVal2     []byte
//	JkVal3     []byte
//	JkVal4     []byte
//	Ts         int64 //记录时间
//}
//
//func NewJackPotLog() *JackPotLog {
//	log := &JackPotLog{LogId: bson.NewObjectId()}
//	return log
//}
//
//func NewJackPotLogEx(gameFreeId int32, platform string, waterVal, jkVal1, jkVal2, jkVal3, jkVal4 int64) *JackPotLog {
//	jackPot := NewJackPotLog()
//	now := time.Now()
//	ts := now.Unix() - int64(now.Second()) - int64(60*now.Minute()) - int64(60*60*now.Hour())
//	jackPot.Platform = platform
//	jackPot.GameFreeId = gameFreeId
//	w, _ := json.Marshal([]JackPot{{Val: waterVal, Ts: ts}})
//	jackPot.WaterVal = w
//	jk1, _ := json.Marshal([]JackPot{{Val: jkVal1, Ts: ts}})
//	jackPot.JkVal1 = jk1
//	jk2, _ := json.Marshal([]JackPot{{Val: jkVal2, Ts: ts}})
//	jackPot.JkVal1 = jk2
//	jk3, _ := json.Marshal([]JackPot{{Val: jkVal3, Ts: ts}})
//	jackPot.JkVal1 = jk3
//	jk4, _ := json.Marshal([]JackPot{{Val: jkVal4, Ts: ts}})
//	jackPot.JkVal1 = jk4
//	jackPot.Ts = ts
//	return jackPot
//}
//
//type DelJKData struct {
//	Platform string
//	Ts       time.Time
//}
//
//func DelJackPotLog(platform string, ts time.Time) error {
//	if rpcCli == nil {
//		return errors.New("rpcCli == nil")
//	}
//	args := &DelJKData{
//		Platform: platform,
//		Ts:       ts,
//	}
//	var ret bool
//	err := rpcCli.CallWithTimeout("JackPotLogSvc.DelJackPotLog", args, &ret, time.Second*30)
//	if err != nil {
//		logger.Logger.Error("model.DelJackPotLog eror.", err)
//	}
//	return err
//}
//func GetJackPotLog(platform string, ts time.Time) (error, []JackPotLog) {
//	if rpcCli == nil {
//		return errors.New("rpcCli == nil"), nil
//	}
//	args := &DelJKData{
//		Platform: platform,
//		Ts:       ts,
//	}
//	var ret []JackPotLog
//	err := rpcCli.CallWithTimeout("JackPotLogSvc.GetJackPotLog", args, &ret, time.Second*30)
//	if err != nil {
//		logger.Logger.Error("model.GetJackPotLog eror.", err)
//	}
//	return err, ret
//}
