forked from enviPath/enviPy
All html files now prettier formatted and fixes for incompatible blocks applied Co-authored-by: Tim Lorsbach <tim@lorsba.ch> Reviewed-on: enviPath/enviPy#193 Co-authored-by: Tobias O <tobias.olenyi@envipath.com> Co-committed-by: Tobias O <tobias.olenyi@envipath.com>
49 lines
1.3 KiB
HTML
49 lines
1.3 KiB
HTML
{% extends "framework.html" %}
|
|
{% load static %}
|
|
{% block content %}
|
|
<div id="searchContent">
|
|
<form id="admin-form" action="{{ SERVER_BASE }}/admin" method="post">
|
|
<div class="form-group">
|
|
<label for="textarea">Query</label>
|
|
<textarea
|
|
id="textarea"
|
|
class="form-control"
|
|
rows="10"
|
|
placeholder="Paste query here"
|
|
required
|
|
>
|
|
PREFIX pps: <http://localhost:8080/vocabulary#>
|
|
SELECT ?name (count(?objId) as ?xcnt)
|
|
WHERE {
|
|
?packageId pps:objectId 'package' .
|
|
?packageId pps:name ?name .
|
|
?packageId pps:reviewStatus 'reviewed' .
|
|
?packageId pps:pathway ?objId .
|
|
} GROUP BY ?name
|
|
</textarea
|
|
>
|
|
</div>
|
|
<button id="submit" type="button" class="btn btn-primary">Submit</button>
|
|
</form>
|
|
<p></p>
|
|
</div>
|
|
<div id="results"></div>
|
|
<div id="loading"></div>
|
|
<script>
|
|
$(function () {
|
|
$("#submit").on("click", function () {
|
|
makeLoadingGif("#loading", "{% static '/images/wait.gif' %}");
|
|
|
|
data = {
|
|
query: $("#textarea").val(),
|
|
};
|
|
|
|
$.post("{{ SERVER_BASE }}/expire", data, function (result) {
|
|
$("#loading").empty();
|
|
queryResultToTable("results", result);
|
|
});
|
|
});
|
|
});
|
|
</script>
|
|
{% endblock content %}
|