mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2026-02-12 01:56:25 +01:00
API SSO, Beautification of Tables, and more. (#562)
# One Thousandth Commit 🎉 🎈 🎆 🍾 * Allow requiring API ownership validation by SSO. Closes #163 * Add Discourse group name length restrictions. * Redirect after api addition/deletion of main character * Correct admin searching for removed discourse_username field in AuthServicesInfo * Correct admin function to sync user Discourse groups * Beautify tables by removing borders and hiding when empty. *Add buttons on dead-end pages to return to originating view.
This commit is contained in:
@@ -9,38 +9,36 @@
|
||||
{% block extra_css %}{% endblock extra_css %}
|
||||
|
||||
{% block content %}
|
||||
<div class="col-lg-12">
|
||||
<div class="col-lg-6 col-lg-offset-3">
|
||||
<div class="row">
|
||||
{% if apikeypairs %}
|
||||
{% else %}
|
||||
<div class="alert alert-danger" role="alert">{% trans "No api keys found" %}</div>
|
||||
{% endif %}
|
||||
<h1 class="page-header text-center">{% trans "API Key Management" %}
|
||||
<div class="text-right">
|
||||
<a href="{% url 'auth_add_api_key' %}" class="btn btn-success">{% trans "Add Key" %}</a>
|
||||
</div>
|
||||
</h1>
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<th class="text-center">{% trans "API ID" %}</th>
|
||||
<th class="text-center">{% trans "API Key" %}</th>
|
||||
<th class="text-center">{% trans "Action" %}</th>
|
||||
</tr>
|
||||
{% for pair in apikeypairs %}
|
||||
{% if apikeypairs %}
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td class="text-center">{{ pair.api_id }}</td>
|
||||
<td class="text-center">{{ pair.api_key }}</td>
|
||||
<td class="text-center">
|
||||
<a href="{% url 'auth_user_refresh_api' pair.api_id %}" class="btn btn-success">
|
||||
<span class="glyphicon glyphicon-refresh"></span>
|
||||
</a>
|
||||
<a href="{% url 'auth_api_key_removal' pair.api_id %}" class="btn btn-danger">
|
||||
<span class="glyphicon glyphicon-remove"></span>
|
||||
</a>
|
||||
</td>
|
||||
<th class="text-center">{% trans "API ID" %}</th>
|
||||
<th class="text-center">{% trans "Action" %}</th>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% for pair in apikeypairs %}
|
||||
<tr>
|
||||
<td class="text-center">{{ pair.api_id }}</td>
|
||||
<td class="text-center">
|
||||
<a href="{% url 'auth_user_refresh_api' pair.api_id %}" class="btn btn-success">
|
||||
<span class="glyphicon glyphicon-refresh"></span>
|
||||
</a>
|
||||
<a href="{% url 'auth_api_key_removal' pair.api_id %}" class="btn btn-danger">
|
||||
<span class="glyphicon glyphicon-remove"></span>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% else %}
|
||||
<div class="alert alert-danger" role="alert">{% trans "No api keys found" %}</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user