Support for disabling password login

This commit is contained in:
Lennart
2025-04-14 18:06:36 +02:00
parent 93b967093c
commit 0b7e6bb7ce
4 changed files with 22 additions and 4 deletions

View File

@@ -7,6 +7,8 @@
{% if let Some(redirect_uri) = redirect_uri %}
<p>and redirect to {{redirect_uri}}</p>
{% endif %}
{% if allow_password_login %}
<form action="login" method="post" id="form_login">
<label for="username">Username</label>
<input type="text" id="username" name="username" placeholder="username">
@@ -19,6 +21,7 @@
{% endif %}
<button type="submit">Login</button>
</form>
{% endif %}
{% if let Some(OidcProviderData {name, redirect_url}) = oidc_data %}
<form action="{{ redirect_url }}" method="post" id="form_login">
@@ -28,6 +31,12 @@
<button type="submit">Login with {{ name }}</button>
</form>
{% endif %}
{% if !allow_password_login && oidc_data.is_none() %}
<p>
No login method available
</p>
{% endif %}
</div>
{% endblock %}