aboutsummaryrefslogtreecommitdiff
path: root/gn3/templates/admin
diff options
context:
space:
mode:
Diffstat (limited to 'gn3/templates/admin')
-rw-r--r--gn3/templates/admin/dashboard.html4
-rw-r--r--gn3/templates/admin/list-oauth2-clients.html45
2 files changed, 49 insertions, 0 deletions
diff --git a/gn3/templates/admin/dashboard.html b/gn3/templates/admin/dashboard.html
index 889e652..52fb7d3 100644
--- a/gn3/templates/admin/dashboard.html
+++ b/gn3/templates/admin/dashboard.html
@@ -13,6 +13,10 @@
title="Register a new OAuth2 client.">Register OAuth2 Client</a>
</li>
<li>
+ <a href="{{url_for('oauth2.admin.list_clients')}}"
+ title="List OAuth2 clients.">List OAuth2 Client</a>
+ </li>
+ <li>
<a href="{{url_for('oauth2.admin.logout')}}"
title="Log out of the system.">Logout</a>
</li>
diff --git a/gn3/templates/admin/list-oauth2-clients.html b/gn3/templates/admin/list-oauth2-clients.html
new file mode 100644
index 0000000..f6bbcb2
--- /dev/null
+++ b/gn3/templates/admin/list-oauth2-clients.html
@@ -0,0 +1,45 @@
+{%extends "base.html"%}
+
+{%block title%}Genenetwork3: OAuth2 Clients{%endblock%}
+
+{%block content%}
+{{flash_messages()}}
+
+<h1>Genenetwork3: OAuth2 Clients</h1>
+
+<table>
+ <legend>List of registered OAuth2 clients</legend>
+ <thead>
+ <tr>
+ <th>Client ID</th>
+ <th>Client Name</th>
+ <th>Default Redirect URI</th>
+ <th>Owner</th>
+ <th>Actions</th>
+ </tr>
+ </thead>
+
+ <tbody>
+ {%for client in clients%}
+ <tr>
+ <td>{{client.client_id}}</td>
+ <td>{{client.client_metadata.client_name}}</td>
+ <td>{{client.client_metadata.default_redirect_uri}}</td>
+ <td>{{client.user.name}} ({{client.user.email}})</td>
+ <td>
+ <a href="#{{client.client_id}}"
+ title"View/Edit client {{client.client_metadata.client_name}}">
+ View/Edit
+ </a>
+ </td>
+ </tr>
+ {%else%}
+ <tr>
+ <td colspan="4" style="text-align: center;">
+ No registered OAuth2 clients!
+ </td>
+ </tr>
+ {%endfor%}
+ </tbody>
+</table>
+{%endblock%}