コード例 #1
0
ファイル: HeatController.cs プロジェクト: ludvikkemp/timataka
 public async Task <IActionResult> AssignMarker(AssignMarkerToHeatViewModel model, int competitionId, int competitionInstanceId, int eventId, int heatId, int markerId)
 {
     if (await _markerService.AssignMarkerToHeatAsync(model) == false)
     {
         return(Json("Guntime already assigned"));
     }
     return(RedirectToAction("Markers", "Heat", new { competitionId, competitionInstanceId, eventId, heatId }));
 }
コード例 #2
0
ファイル: MarkerService.cs プロジェクト: ludvikkemp/timataka
        public async Task <Boolean> UnassignMarkerAsync(AssignMarkerToHeatViewModel model)
        {
            var result = await _repo.RemoveMarkerInHeatAsync(new MarkerInHeat { HeatId = model.HeatId, MarkerId = model.MarkerId });

            return(result);
        }