nopaque/app/templates/admin/corpora.html.j2
Patrick Jentsch 5b6eae7645 Cleanup
2023-03-23 17:42:51 +01:00

31 lines
686 B
Django/Jinja

{% extends "base.html.j2" %}
{% block page_content %}
<div class="container">
<h1 id="title">{{ title }}</h1>
<div class="card">
<div class="card-content">
<div class="corpus-list no-autoinit" id="corpus-list"></div>
</div>
</div>
</div>
</div>
{% endblock page_content %}
{% block scripts %}
{{ super() }}
<script>
let corpusListElement = document.querySelector('#corpus-list');
let corpusList = new CorpusList(corpusListElement);
corpusList.add(
[
{% for corpus in corpora %}
{{ corpus.to_json_serializeable(backrefs=True)|tojson }}
{% if not loop.last %},{% endif %}
{% endfor %}
]
);
</script>
{% endblock scripts %}