26 lines
1.3 KiB
Plaintext
26 lines
1.3 KiB
Plaintext
@{
|
|
string myClass = "";
|
|
}
|
|
|
|
<div aria-label="breadcrumb">
|
|
<ol class="breadcrumb">
|
|
@if (ViewContext.RouteData.Values["controller"].ToString() == "Home" && ViewContext.RouteData.Values["action"].ToString() == "Index")
|
|
myClass = "active disableLink";
|
|
<li class="breadcrumb-item @myClass">@Html.ActionLink("Home", "Index", "Home")</li>
|
|
@if (ViewContext.RouteData.Values["controller"].ToString() != "Home")
|
|
{
|
|
if (ViewContext.RouteData.Values["action"].ToString() == "Index")
|
|
myClass = "active disableLink";
|
|
|
|
<li class="breadcrumb-item @myClass">@Html.ActionLink(APIHelperFunctions.SplitOnCamelCase(ViewContext.RouteData.Values["controller"].ToString()) + "s", "Index", ViewContext.RouteData.Values["controller"].ToString())</li>
|
|
}
|
|
@if (ViewContext.RouteData.Values["action"].ToString() != "Index")
|
|
{
|
|
if (ViewContext.RouteData.Values["controller"].ToString() != "Home")
|
|
myClass = "active disableLink";
|
|
|
|
<li class="breadcrumb-item @myClass">@Html.ActionLink(APIHelperFunctions.SplitOnCamelCase(ViewContext.RouteData.Values["action"].ToString()), ViewContext.RouteData.Values["action"].ToString(), ViewContext.RouteData.Values["controller"].ToString())</li>
|
|
}
|
|
</ol>
|
|
</div>
|
|
<br /> |