aboutsummaryrefslogtreecommitdiff
path: root/uploader/templates
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi2024-07-29 13:19:03 -0500
committerFrederick Muriuki Muriithi2024-08-05 09:52:17 -0500
commit889ff3116c8e412bb8bf969bd9484269ee716cb0 (patch)
treedd16324b7bc6b135dc60bfb17ecdcefeeb713bb3 /uploader/templates
parent92d0d0c387fd9d41c8371fcef7d3bd5beacdc2ac (diff)
downloadgn-uploader-889ff3116c8e412bb8bf969bd9484269ee716cb0.tar.gz
Enable logout.
Diffstat (limited to 'uploader/templates')
-rw-r--r--uploader/templates/base.html13
-rw-r--r--uploader/templates/index.html3
-rw-r--r--uploader/templates/login.html3
3 files changed, 18 insertions, 1 deletions
diff --git a/uploader/templates/base.html b/uploader/templates/base.html
index eb5e6b7..ee60fea 100644
--- a/uploader/templates/base.html
+++ b/uploader/templates/base.html
@@ -33,7 +33,18 @@
<ul class="nav navbar-nav">
<li><a href="/" style="font-weight: bold">GN Uploader</a></li>
<li>
- <a href="{{gnuri or 'https://genenetwork.org'}}">GeneNetwork</a>
+ <a href="{{gn2server_uri()}}">GeneNetwork</a>
+ </li>
+ </ul>
+ <ul class="nav navbar-nav" style="margin-left: 2em;">
+ <li>
+ {%if user_logged_in()%}
+ <a href="{{url_for('oauth2.logout')}}"
+ title="Log out of the system">Log Out</a>
+ {%else%}
+ <a href="{{authserver_authorise_uri()}}"
+ title="Log in to the system">Log In</a>
+ {%endif%}
</li>
</ul>
</div>
diff --git a/uploader/templates/index.html b/uploader/templates/index.html
index 89d2ae9..94060b7 100644
--- a/uploader/templates/index.html
+++ b/uploader/templates/index.html
@@ -1,9 +1,12 @@
{%extends "base.html"%}
+{%from "flash_messages.html" import flash_all_messages%}
{%block title%}Data Upload{%endblock%}
{%block contents%}
<div class="row">
+ {{flash_all_messages()}}
+
<h1 class="heading">data upload</h1>
<div class="explainer">
diff --git a/uploader/templates/login.html b/uploader/templates/login.html
index 68510aa..6ebf72e 100644
--- a/uploader/templates/login.html
+++ b/uploader/templates/login.html
@@ -1,9 +1,12 @@
{%extends "base.html"%}
+{%from "flash_messages.html" import flash_all_messages%}
{%block title%}Data Upload{%endblock%}
{%block contents%}
<div class="row">
+ {{flash_all_messages()}}
+
<h1 class="heading">log in</h1>
<div class="explainer">