(c *gin.Context)
| 129 | } |
| 130 | |
| 131 | func GetRoomInfo(c *gin.Context) { |
| 132 | var formRoomInfo FormRoomInfo |
| 133 | if err := c.ShouldBindBodyWith(&formRoomInfo, binding.JSON); err != nil { |
| 134 | tools.FailWithMsg(c, err.Error()) |
| 135 | return |
| 136 | } |
| 137 | roomId := formRoomInfo.RoomId |
| 138 | req := &proto.Send{ |
| 139 | RoomId: roomId, |
| 140 | Op: config.OpRoomInfoSend, |
| 141 | } |
| 142 | code, msg := rpc.RpcLogicObj.GetRoomInfo(req) |
| 143 | if code == tools.CodeFail { |
| 144 | tools.FailWithMsg(c, "rpc get room info fail!") |
| 145 | return |
| 146 | } |
| 147 | tools.SuccessWithMsg(c, "ok", msg) |
| 148 | return |
| 149 | } |
nothing calls this directly
no test coverage detected