av.go 630 B

123456789101112131415161718192021222324
  1. package dao
  2. import (
  3. "context"
  4. "go-common/app/service/live/av/api/liverpc/v1"
  5. "go-common/library/log"
  6. )
  7. // GetFansMedalInfo 获取粉丝勋章信息
  8. func (d *Dao) GetPkStatus(c context.Context, roomId int64) (resp *v1.PkGetPkStatusResp_Data, err error) {
  9. reply, err := d.AvApi.V1Pk.GetPkStatus(c, &v1.PkGetPkStatusReq{RoomId: roomId})
  10. if err != nil {
  11. log.Error("av_GetPkStatus_error:%v", err)
  12. return
  13. }
  14. if reply.Code != 0 {
  15. log.Error("av_GetPkStatus_error:%d,%s,%v", reply.Code, reply.Msg, reply.Data)
  16. return
  17. }
  18. log.Info("av_GetPkStatus:%d,%s,$v", reply.Code, reply.Msg, reply.Data)
  19. resp = reply.Data
  20. return
  21. }