Completed app page + added metar class
This commit is contained in:
@ -23,18 +23,17 @@ namespace EFB.Controllers
|
||||
public IActionResult Index()
|
||||
{
|
||||
//Check to see what point on the application the user is at and where they should be sent
|
||||
UserModel User = HttpContext.Session.GetObject<UserModel>("User");
|
||||
if (User != null)
|
||||
UserModel user = HttpContext.Session.GetObject<UserModel>("User");
|
||||
if (user == null)
|
||||
{
|
||||
if (User.Route == null)
|
||||
{
|
||||
return RedirectToAction("Index", "Route");
|
||||
}else{
|
||||
return RedirectToAction("Index", "App");
|
||||
}
|
||||
}else{
|
||||
return RedirectToAction("Index", "Home");
|
||||
return RedirectToAction("Index", "Home");
|
||||
}
|
||||
if (user.Route == null)
|
||||
{
|
||||
return RedirectToAction("Index", "Route");
|
||||
}
|
||||
|
||||
return View(user);
|
||||
}
|
||||
|
||||
[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)]
|
||||
|
@ -185,7 +185,7 @@ namespace EFB.Controllers
|
||||
user.Cruise = cruise;
|
||||
HttpContext.Session.SetObject("User", user);
|
||||
|
||||
return RedirectToAction("Index", "Route");
|
||||
return RedirectToAction("Index", "App");
|
||||
}
|
||||
|
||||
TempData["Error"] = $"Unable to get route after {pollCount} Attempts!";
|
||||
|
Reference in New Issue
Block a user