mirror of
https://github.com/akuker/RASCSI.git
synced 2024-06-10 17:29:35 +00:00
Show Settings button when auth is diabled
This commit is contained in:
parent
f4e782fe20
commit
a48a4429b1
|
@ -282,18 +282,6 @@ div.header div.login-form-title {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.header div.authentication-disabled span.separator {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.header div.authentication-disabled span.wiki-help-text {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.header div.authentication-disabled a {
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 900px) {
|
@media (max-width: 900px) {
|
||||||
div.header {
|
div.header {
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
|
|
@ -27,37 +27,31 @@
|
||||||
|
|
||||||
<body class="{{ body_classes|join(' ') }}">
|
<body class="{{ body_classes|join(' ') }}">
|
||||||
<div class="header">
|
<div class="header">
|
||||||
{% if env["auth_active"] %}
|
{% if env["logged_in"] or not env["auth_active"] %}
|
||||||
|
<div align="center" class="login-status logged-in">
|
||||||
{% if env["logged_in"] %}
|
{% if env["logged_in"] %}
|
||||||
<div align="center" class="login-status logged-in">
|
<span class="logged-in-as-text">{{ _("Logged in as <em>%(username)s</em>", username=env["username"]) }}</span>
|
||||||
<span class="logged-in-as-text">{{ _("Logged in as <em>%(username)s</em>", username=env["username"]) }}</span>
|
<span class="separator">-</span>
|
||||||
<span class="separator">-</span>
|
<span class="log-out-button"><a href="/logout">{{ _("Log Out") }}</a></span>
|
||||||
<span class="log-out-button"><a href="/logout">{{ _("Log Out") }}</a></span>
|
<span class="separator">-</span>
|
||||||
<span class="separator">-</span>
|
|
||||||
<span class="admin-button"><a href="/sys/admin">{{ _("Settings") }}</a></span>
|
|
||||||
</div>
|
|
||||||
{% else %}
|
|
||||||
<div align="center" class="login-status logged-out">
|
|
||||||
<form method="POST" action="/login">
|
|
||||||
<div class="login-form-title">{{ _("Log in to use Web Interface") }}</div>
|
|
||||||
<span>
|
|
||||||
<label for="username">{{ _("Username:") }}</label>
|
|
||||||
<input type="text" name="username" id="username">
|
|
||||||
</span>
|
|
||||||
<span>
|
|
||||||
<label for="password">{{ _("Password:") }}</label>
|
|
||||||
<input type="password" name="password" id="password">
|
|
||||||
</span>
|
|
||||||
<input type="submit" value="Login">
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
<span class="admin-button"><a href="/sys/admin">{{ _("Settings") }}</a></span>
|
||||||
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
<div align="center" class="login-status authentication-disabled">
|
<div align="center" class="login-status logged-out">
|
||||||
<span class="authentication-disabled-text">{{ _("Web Interface Authentication Disabled") }}</span>
|
<form method="POST" action="/login">
|
||||||
<span class="separator">-</span>
|
<div class="login-form-title">{{ _("Log in to use Web Interface") }}</div>
|
||||||
<span class="wiki-help-text">{{ _("See <a href=\"%(url)s\" target=\"_blank\">Wiki</a> for more information", url="https://github.com/PiSCSI/piscsi/wiki/Web-Interface#enable-authentication") }}</span>
|
<span>
|
||||||
</div>
|
<label for="username">{{ _("Username:") }}</label>
|
||||||
|
<input type="text" name="username" id="username">
|
||||||
|
</span>
|
||||||
|
<span>
|
||||||
|
<label for="password">{{ _("Password:") }}</label>
|
||||||
|
<input type="password" name="password" id="password">
|
||||||
|
</span>
|
||||||
|
<input type="submit" value="Login">
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<div align="center" class="title">
|
<div align="center" class="title">
|
||||||
|
|
Loading…
Reference in New Issue
Block a user