diff options
author | John Nduli | 2024-09-10 15:38:15 +0300 |
---|---|---|
committer | BonfaceKilz | 2024-09-17 11:40:42 +0300 |
commit | 44d3ab8d7070317241f0348edcf57fb4c3b044ca (patch) | |
tree | 5a470e55efdf45b2a9560c0ba3c39e5dc143cb1b /gn2/wqflask/templates/wiki | |
parent | 6b2ee8f7ac6b90a53480f2b51289221fb59d5bc0 (diff) | |
download | genenetwork2-44d3ab8d7070317241f0348edcf57fb4c3b044ca.tar.gz |
feat: hide edit button if user isnt logged in
Diffstat (limited to 'gn2/wqflask/templates/wiki')
-rw-r--r-- | gn2/wqflask/templates/wiki/genewiki.html | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gn2/wqflask/templates/wiki/genewiki.html b/gn2/wqflask/templates/wiki/genewiki.html index 36aa41c1..f0d6675f 100644 --- a/gn2/wqflask/templates/wiki/genewiki.html +++ b/gn2/wqflask/templates/wiki/genewiki.html @@ -11,7 +11,9 @@ <h5> <strong>GeneNetwork:</strong> </h5> + {% if wiki %} + <ol class="list-group"> {% for entry in wiki %} <li class="list-group-item"> @@ -23,12 +25,16 @@ <sup> <small> <a href = "{{ entry.web_url }}" target = "_blank"> <span class = "glyphicon glyphicon-globe" aria-hidden = "true"></span>web</a></small></sup> {% endif %} </div> + + {% if is_logged_in %} <div class="col-sm-2"> <a href="{{ url_for('edit_wiki', comment_id=entry['id']) }}"> <span class="glyphicon glyphicon-edit" aria-hidden="true"></span> </a> </div> + {% endif %} <sup><small>[<a href="/genewiki/{{ entry.id }}/history" target="_blank">history</a>]</small></sup> + </div> </li> {% endfor %} </ol> |