Exemplo n.º 1
0
        public async Task <IActionResult> CreateRandomTeamsForMatch(Guid id)
        {
            _Logger.LogInformation($"Teams: {HelperMethods.GetCallerMemberName()}");

            var update = await _generationService.ExecuteTeamGenerationForMatchAndUpdate(id, GeneratorType.Random);

            if (update)
            {
                return(Ok());
            }
            return(BadRequest("Team Generation Failed"));
        }
Exemplo n.º 2
0
 public async Task <bool> Handle(RandomTeamCreateCommand request, CancellationToken cancellationToken)
 {
     return(await _GenerationService.ExecuteTeamGenerationForMatchAndUpdate(request.MatchId
                                                                            , Domain.Enums.GeneratorType.Random));
 }