获奖记录
This commit is contained in:
parent
107ac98d81
commit
e318c85c26
|
|
@ -2948,7 +2948,11 @@ func CSAwardLog(s *netlib.Session, packetId int, data interface{}, sid int64) er
|
||||||
infoData := &player_proto.AnnouncerLogInfo{}
|
infoData := &player_proto.AnnouncerLogInfo{}
|
||||||
//infoData.Snid = logInfo.Snid
|
//infoData.Snid = logInfo.Snid
|
||||||
infoData.Name = logInfo.Name
|
infoData.Name = logInfo.Name
|
||||||
infoData.Phone = logInfo.Phone[len(logInfo.Phone)-4:]
|
str := ""
|
||||||
|
if len(logInfo.Phone) > 4 {
|
||||||
|
str = logInfo.Phone[:4]
|
||||||
|
}
|
||||||
|
infoData.Phone = str
|
||||||
infoData.ItemId = logInfo.ItemId
|
infoData.ItemId = logInfo.ItemId
|
||||||
infoData.TypeId = logInfo.TypeId
|
infoData.TypeId = logInfo.TypeId
|
||||||
ret.AnnouncerLog = append(ret.AnnouncerLog, infoData)
|
ret.AnnouncerLog = append(ret.AnnouncerLog, infoData)
|
||||||
|
|
@ -2962,7 +2966,11 @@ func CSAwardLog(s *netlib.Session, packetId int, data interface{}, sid int64) er
|
||||||
infoData := &player_proto.AnnouncerLogInfo{}
|
infoData := &player_proto.AnnouncerLogInfo{}
|
||||||
//infoData.Snid = info.Snid
|
//infoData.Snid = info.Snid
|
||||||
infoData.Name = info.Name
|
infoData.Name = info.Name
|
||||||
infoData.Phone = info.Phone[len(info.Phone)-4:]
|
str := ""
|
||||||
|
if len(info.Phone) > 4 {
|
||||||
|
str = info.Phone[:4]
|
||||||
|
}
|
||||||
|
infoData.Phone = str
|
||||||
infoData.ItemId = info.ItemId
|
infoData.ItemId = info.ItemId
|
||||||
infoData.TypeId = info.TypeId
|
infoData.TypeId = info.TypeId
|
||||||
ret.AnnouncerLog = append(ret.AnnouncerLog, infoData)
|
ret.AnnouncerLog = append(ret.AnnouncerLog, infoData)
|
||||||
|
|
|
||||||
|
|
@ -59,6 +59,7 @@ func (this *AwardLogManager) UpdateAnnouncerLog(data model.AnnouncerLog) {
|
||||||
}
|
}
|
||||||
this.AnnouncerLog[data.TypeId] = append(this.AnnouncerLog[data.TypeId], data)
|
this.AnnouncerLog[data.TypeId] = append(this.AnnouncerLog[data.TypeId], data)
|
||||||
logger.Logger.Trace("更新实时播报数据 this.AnnouncerLog = ", this.AnnouncerLog)
|
logger.Logger.Trace("更新实时播报数据 this.AnnouncerLog = ", this.AnnouncerLog)
|
||||||
|
data.Ts = time.Now()
|
||||||
err := model.InsertAnnouncerLog(&data)
|
err := model.InsertAnnouncerLog(&data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.Logger.Error("UpdateAnnouncerLog InsertAnnouncerLog err :", err)
|
logger.Logger.Error("UpdateAnnouncerLog InsertAnnouncerLog err :", err)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue