Exemplo n.º 1
0
        public async Task <IActionResult> Create(StatusCreateDto teamDto)
        {
            if (await _teamService.CheckExists(teamDto.ID))
            {
                return(BadRequest("Status ID already exists!"));
            }
            //var username = User.FindFirst(ClaimTypes.Name).Value;
            //glueIngredientDto.Updated_By = username;
            if (await _teamService.Add(teamDto))
            {
                return(NoContent());
            }

            throw new Exception("Creating the team failed on save");
        }