コード例 #1
0
        public async Task <InitialResponseData> GetInitialDate(InitialRequestData requestData)
        {
            var result = new InitialResponseData();

            var res = await _context.PlayerStatistics.FirstOrDefaultAsync(t => t.PlayerId == requestData.PlayerId);

            if (res == null)
            {
                return(result);
            }

            result.Kills       = res.Kills;
            result.Deaths      = res.Deaths;
            result.Assists     = res.Assists;
            result.GamesPlayed = res.GamesPlayed;
            result.GamesWon    = res.GamesWon;
            result.GameLose    = res.GameLose;
            result.PlayerId    = res.PlayerId;

            return(result);
        }
コード例 #2
0
 public async Task <InitialResponseData> GetInitialData(InitialRequestData model)
 {
     return(await _homeService.GetInitialDate(model));
 }