aboutsummaryrefslogtreecommitdiff
path: root/gn2/wqflask/templates/wiki/history.html
diff options
context:
space:
mode:
authorMunyoki Kilyungi2024-09-04 12:47:40 +0300
committerBonfaceKilz2024-09-05 16:41:17 +0300
commit233d4b7725849c246f646a54b33e2106fbf2e4bc (patch)
tree5bffa42b71028db1f6f156032f5be1b0c391ea8e /gn2/wqflask/templates/wiki/history.html
parent11d54f83b5920834075508cad8ad73a707ccd41c (diff)
downloadgenenetwork2-233d4b7725849c246f646a54b33e2106fbf2e4bc.tar.gz
Remove un-necessary "if" checks in comment history page.
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
Diffstat (limited to 'gn2/wqflask/templates/wiki/history.html')
-rw-r--r--gn2/wqflask/templates/wiki/history.html188
1 files changed, 91 insertions, 97 deletions
diff --git a/gn2/wqflask/templates/wiki/history.html b/gn2/wqflask/templates/wiki/history.html
index d0a3ead6..77c8e9f7 100644
--- a/gn2/wqflask/templates/wiki/history.html
+++ b/gn2/wqflask/templates/wiki/history.html
@@ -25,117 +25,111 @@
{{ flash_me() }}
<div class = "container container-fluid">
<h2>GeneWiki Entry History</h2>
- {% if most_recent %}
- <h3>
- <strong>Most Recent Version:</strong>
- </h3>
- <table class="table table-responsive table-bordered">
- <tbody>
+ <h3>
+ <strong>Most Recent Version:</strong>
+ </h3>
+ <table class="table table-responsive table-bordered">
+ <tbody>
+ <tr>
+ <th>Gene Symbol:</th>
+ <td>{{ most_recent["symbol"] }}</td>
+ </tr>
+ {% if most_recent["species"] %}
<tr>
- <th>Gene Symbol:</th>
- <td>{{ most_recent["symbol"] }}</td>
+ <th>Species:</th>
+ <td>{{ most_recent["species"] }}</td>
</tr>
- {% if most_recent["species"] %}
- <tr>
- <th>Species:</th>
- <td>{{ most_recent["species"] }}</td>
- </tr>
- {% endif %}
- {% if most_recent["pubmed_ids"] %}
- <tr>
- <th>PubMed IDs:</th>
- <td>
- {% for id in most_recent["pubmed_ids"] %}
- <a href="http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?cmd=Retrieve&db=PubMed&list_uids={{ id }}&dopt=Abstract">{{ id }}</a>&nbsp;
- {% endfor %}
- </td>
- </tr>
- {% endif %}
- {% if most_recent["web_url"] %}
- <tr>
- <th>Web URL:</th>
- <td>{{ most_recent["web_url"] }}</td>
- </tr>
- {% endif %}
+ {% endif %}
+ {% if most_recent["pubmed_ids"] %}
<tr>
- <th>Entry:</th>
- <td>{{ most_recent["comment"] }}</td>
+ <th>PubMed IDs:</th>
+ <td>
+ {% for id in most_recent["pubmed_ids"] %}
+ <a href="http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?cmd=Retrieve&db=PubMed&list_uids={{ id }}&dopt=Abstract">{{ id }}</a>&nbsp;
+ {% endfor %}
+ </td>
</tr>
- {% if most_recent["categories"] %}
- <tr>
- <th>Category:</th>
- <td>{{ '; '.join(most_recent["categories"]) }}</td>
- </tr>
- {% endif %}
+ {% endif %}
+ {% if most_recent["web_url"] %}
<tr>
- <th>Add Time:</th>
- <td>{{ most_recent["created"] }}</td>
+ <th>Web URL:</th>
+ <td>{{ most_recent["web_url"] }}</td>
</tr>
- {% if most_recent["reason"] %}
- <tr>
- <th>Reason for Modification:</th>
- <td>{{ most_recent["reason"] }}</td>
- </tr>
- {% endif %}
- </tbody>
- </table>
- {% endif %}
+ {% endif %}
+ <tr>
+ <th>Entry:</th>
+ <td>{{ most_recent["comment"] }}</td>
+ </tr>
+ {% if most_recent["categories"] %}
+ <tr>
+ <th>Category:</th>
+ <td>{{ '; '.join(most_recent["categories"]) }}</td>
+ </tr>
+ {% endif %}
+ <tr>
+ <th>Add Time:</th>
+ <td>{{ most_recent["created"] }}</td>
+ </tr>
+ {% if most_recent["reason"] %}
+ <tr>
+ <th>Reason for Modification:</th>
+ <td>{{ most_recent["reason"] }}</td>
+ </tr>
+ {% endif %}
+ </tbody>
+ </table>
<h3>
<strong>Previous Version:</strong>
</h3>
- {% if previous_versions %}
- {% for version in previous_versions %}
- <table class="table table-responsive table-bordered">
+ {% for version in previous_versions %}
+ <table class="table table-responsive table-bordered">
+ <tr>
+ <th>Gene Symbol:</th>
+ <td>{{ version["symbol"] }}</td>
+ </tr>
+ {% if version["species"] %}
+ <tr>
+ <th>Species:</th>
+ <td>{{ version["species"] }}</td>
+ </tr>
+ {% endif %}
+ {% if version["pubmed_ids"] %}
<tr>
- <th>Gene Symbol:</th>
- <td>{{ version["symbol"] }}</td>
+ <th>PubMed IDs:</th>
+ <td>
+ {% for id in version["pubmed_ids"] %}
+ <a href="http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?cmd=Retrieve&db=PubMed&list_uids={{ id }}&dopt=Abstract">{{ id }}</a>&nbsp;
+ {% endfor %}
+ </td>
</tr>
- {% if version["species"] %}
- <tr>
- <th>Species:</th>
- <td>{{ version["species"] }}</td>
- </tr>
- {% endif %}
- {% if version["pubmed_ids"] %}
- <tr>
- <th>PubMed IDs:</th>
- <td>
- {% for id in version["pubmed_ids"] %}
- <a href="http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?cmd=Retrieve&db=PubMed&list_uids={{ id }}&dopt=Abstract">{{ id }}</a>&nbsp;
- {% endfor %}
- </td>
- </tr>
- {% endif %}
- {% if version["web_url"] %}
- <tr>
- <th>Web URL:</th>
- <td>{{ version["web_url"] }}</td>
- </tr>
- {% endif %}
+ {% endif %}
+ {% if version["web_url"] %}
<tr>
- <th>Entry:</th>
- <td>{{ version["comment"] }}</td>
+ <th>Web URL:</th>
+ <td>{{ version["web_url"] }}</td>
</tr>
- {% if version["categories"] %}
- <tr>
- <th>Category:</th>
- <td>{{ '; '.join(version["categories"]) }}</td>
- </tr>
- {% endif %}
+ {% endif %}
+ <tr>
+ <th>Entry:</th>
+ <td>{{ version["comment"] }}</td>
+ </tr>
+ {% if version["categories"] %}
<tr>
- <th>Add Time:</th>
- <td>{{ version["created"] }}</td>
+ <th>Category:</th>
+ <td>{{ '; '.join(version["categories"]) }}</td>
</tr>
- {% if version["reason"] %}
- <tr>
- <th>Reason for Modification:</th>
- <td>{{ version["reason"] }}</td>
- </tr>
- {% endif %}
- </table>
- {% endfor %}
- {% else %}
- <p>No Previous History</p>
- {% endif %}
+ {% endif %}
+ <tr>
+ <th>Add Time:</th>
+ <td>{{ version["created"] }}</td>
+ </tr>
+ {% if version["reason"] %}
+ <tr>
+ <th>Reason for Modification:</th>
+ <td>{{ version["reason"] }}</td>
+ </tr>
+ {% endif %}
+ </table>
+ {% endfor %}
</div>
{% endblock %}