Сделал третью страницу
All checks were successful
Create and publish a Docker image / build-and-push-image (push) Successful in 24s
All checks were successful
Create and publish a Docker image / build-and-push-image (push) Successful in 24s
This commit is contained in:
@ -40,7 +40,7 @@ public class HomeController : Controller
|
||||
if (universityId == 0)
|
||||
return RedirectToAction("Index");
|
||||
|
||||
var answer = new UniversityDirectionsViewModel();
|
||||
var answer = new DirectionsViewModel();
|
||||
answer.University = await _universityService.GetUniversityById(universityId);
|
||||
answer.Directions = await _universityService.GetDirectionsByUniversityId(universityId);
|
||||
answer.SearchString = searchString;
|
||||
@ -54,9 +54,17 @@ public class HomeController : Controller
|
||||
}
|
||||
|
||||
[Route("Credits")]
|
||||
public IActionResult Credits()
|
||||
public async Task<IActionResult> Credits(long universityId, long directionId, string searchString)
|
||||
{
|
||||
return View();
|
||||
if (universityId == 0 || directionId == 0)
|
||||
return RedirectToAction("Index");
|
||||
|
||||
var answer = new CreditsViewModel();
|
||||
answer.University = await _universityService.GetUniversityById(universityId);;
|
||||
answer.Direction = await _universityService.GetDirectionsById(directionId);
|
||||
answer.Offers = await _universityService.GetOffers(directionId);
|
||||
|
||||
return View(answer);
|
||||
}
|
||||
|
||||
public IActionResult Privacy()
|
||||
|
Reference in New Issue
Block a user