コード例 #1
0
 public ActionResult Edit(int id, OddsData data)
 {
     try
     {
         data.Id = id;
         _oddsLogic.EditOdds(data);
         return(RedirectToAction(nameof(Index)));
     }
     catch
     {
         return(View());
     }
 }
コード例 #2
0
 public async Task SendUpdatedOdds(List <OddsData> data)
 {
     _oddsLogic.EditOdds(data);
     var result = _oddsLogic.GetOdds(data.Select(x => x.Id).ToArray());
     await Clients.All.SendAsync(actionUpdateOdds, result);
 }