diff --git a/Controllers/HomeController.cs b/Controllers/HomeController.cs index d7e2d58..56eae08 100644 --- a/Controllers/HomeController.cs +++ b/Controllers/HomeController.cs @@ -55,9 +55,9 @@ namespace CarCareTracker.Controllers { return int.Parse(User.FindFirstValue(ClaimTypes.NameIdentifier)); } - public IActionResult Index(string tab = "garage") + public IActionResult Index() { - return View(model: tab); + return View(); } [Route("/kiosk")] public IActionResult Kiosk(string exclusions, KioskMode kioskMode = KioskMode.Vehicle) diff --git a/Helper/StaticHelper.cs b/Helper/StaticHelper.cs index fcf0dd8..5bb01c9 100644 --- a/Helper/StaticHelper.cs +++ b/Helper/StaticHelper.cs @@ -123,27 +123,13 @@ namespace CarCareTracker.Helper } public static string DefaultActiveTab(UserConfig userConfig, ImportMode tab) { - var defaultTab = userConfig.DefaultTab; var visibleTabs = userConfig.VisibleTabs; - if (visibleTabs.Contains(tab) && tab == defaultTab) - { - return "active"; - } - else if (!visibleTabs.Contains(tab)) + if (!visibleTabs.Contains(tab)) { return "d-none"; } return ""; } - public static string DefaultActiveTabContent(UserConfig userConfig, ImportMode tab) - { - var defaultTab = userConfig.DefaultTab; - if (tab == defaultTab) - { - return "show active"; - } - return ""; - } public static string DefaultTabSelected(UserConfig userConfig, ImportMode tab) { var defaultTab = userConfig.DefaultTab; diff --git a/Views/Home/Index.cshtml b/Views/Home/Index.cshtml index 4fad162..f3b3769 100644 --- a/Views/Home/Index.cshtml +++ b/Views/Home/Index.cshtml @@ -5,7 +5,6 @@ var userConfig = config.GetUserConfig(User); var userLanguage = userConfig.UserLanguage; } -@model string @{ ViewData["Title"] = "Garage"; } @@ -25,7 +24,7 @@ @if (User.IsInRole("CookieAuth") || User.IsInRole("APIAuth")) { @@ -88,7 +87,7 @@
-
-
- -
+
-
+
@@ -172,7 +168,8 @@
\ No newline at end of file diff --git a/Views/Home/_GarageDisplay.cshtml b/Views/Home/_GarageDisplay.cshtml index fff08b4..5eeb8f5 100644 --- a/Views/Home/_GarageDisplay.cshtml +++ b/Views/Home/_GarageDisplay.cshtml @@ -10,6 +10,7 @@ var searchExist = userConfig.ShowSearch && Model.Count() > 1; var renderTopRow = tagsExist || searchExist; } +
@if (renderTopRow) {
@@ -101,4 +102,5 @@
-
\ No newline at end of file +
+ \ No newline at end of file diff --git a/Views/Vehicle/Index.cshtml b/Views/Vehicle/Index.cshtml index 541d26a..9988f90 100644 --- a/Views/Vehicle/Index.cshtml +++ b/Views/Vehicle/Index.cshtml @@ -136,17 +136,17 @@
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+