diff options
author | Frederick Muriuki Muriithi | 2023-06-30 09:19:39 +0300 |
---|---|---|
committer | Frederick Muriuki Muriithi | 2023-06-30 09:19:39 +0300 |
commit | cd16f99aa23123f2398e3a3a542d84363d7a7b16 (patch) | |
tree | 019eadec715989ee80cc62f5f78070d54dc8c75d /gn3/templates | |
parent | d46d1eb47f9ee18518894d850a18cd952231dddc (diff) | |
download | genenetwork3-cd16f99aa23123f2398e3a3a542d84363d7a7b16.tar.gz |
List all OAuth2 clients.
Diffstat (limited to 'gn3/templates')
-rw-r--r-- | gn3/templates/admin/dashboard.html | 4 | ||||
-rw-r--r-- | gn3/templates/admin/list-oauth2-clients.html | 45 |
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%} |