public async Task CreateAsync(SolutionCreateBindingModel model, int teamId)
        {
            var solution = this.Mapper.Map <Solution>(model);

            solution.TeamId = teamId;

            var statusWithType = await this.AddStatusForSolutionAsync(solution);

            solution.StatusId = statusWithType.Id;

            this.DbContext.SaveChanges();
        }
Ejemplo n.º 2
0
        public async Task <IActionResult> Create(SolutionCreateBindingModel model, int id)
        {
            if (!ModelState.IsValid)
            {
                return(View());
            }

            int teamId = int.Parse(TempData["TeamId"].ToString());

            await this.developerSolutionsService.CreateAsync(model, id);

            return(RedirectToAction("Details"));
        }