poke/core/LightTube/Views/Shared/_LoginLogoutPartial.cshtml
2022-08-05 22:33:38 +03:00

17 lines
561 B
Plaintext

@using LightTube.Database
@if (Context.TryGetUser(out LTUser user, "web"))
{
<div class="guide-item"><a>@user.UserID.Split("@")[0]</a></div>
@if (user.PasswordHash != "local_account")
{
<div class="guide-item"><a href="/Account/Logins">Active logins</a></div>
}
<div class="guide-item"><a href="/Account/Logout">Log out</a></div>
}
else
{
<div class="guide-item"><a href="/Account/Login">Log in</a></div>
<div class="guide-item"><a href="/Account/Register">Register</a></div>
}
<div class="guide-item"><a href="/Account/Settings">Settings</a></div>