using Assets.Scripts.Apis.Models; using Newtonsoft.Json; using Newtonsoft.Json.Linq; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Assets.Scripts.Apis { public class GameRoomApi : ApiBase { public JsonResult Add(GameRoomModel record, List fileNames) { var result = Upload("GameRoom/Add", record, fileNames); var jsonResult = JsonConvert.DeserializeObject>(result); return jsonResult; } public async Task>> GetList(int pageIndex, int pageSize,int? id = null) { return await GetAsync>>($"GameRoom/GetList?pageIndex={pageIndex}&pageSize={pageSize}&id={id}"); } public async Task> GetDetail(int id) { return await GetAsync>($"GameRoom/GetDetail?Id={id}"); } } }