Skip to content
Snippets Groups Projects
Commit 1cb01bd7 authored by Martin Staehr's avatar Martin Staehr
Browse files

fix naming of id

parent f1325502
No related branches found
No related tags found
No related merge requests found
......@@ -73,7 +73,7 @@
{{for categories}}
<li class="spacing">
<div id="{{>name}}" class="category-card not-added">
<div id="{{>nameLower}}" class="category-card not-added">
<p>{{>name}}</p>
</div>
</li>
......
......@@ -2,6 +2,9 @@
* This function will fire when the DOM is ready
*/
const staticCategories = [{name: "TITEL"}, {name: "RECHERCHE"}, {name: "LITERATURVERZEICHNIS"}, {name: "FORSCHUNGSFRAGE"}, {name: "UNTERSUCHUNGSKONZEPT"},
{name: "METHODIK"}, {name: "DURCHFUEHRUNG"}, {name: "AUSWERTUNG"}]
$(document).ready(function () {
$('#missingAnnotation').hide();
buildAnnotationList();
......@@ -250,9 +253,10 @@ function handleCategoryClick(key, color) {
}
function buildAnnotationList() {
let data = {categories: [{name: "TITEL"}, {name: "RECHERCHE"}, {name: "LITERATURVERZEICHNIS"}, {name: "FORSCHUNGSFRAGE"}, {name: "UNTERSUCHUNGSKONZEPT"},
{name: "METHODIK"}, {name: "DURCHFUEHRUNG"}, {name: "AUSWERTUNG"}]};
let data = {categories: []};
staticCategories.forEach(function(category) {
data.categories.push({name: category.name, nameLower: category.name.toLowerCase()})
});
let tmpl = $.templates("#annotationTemplate");
let html = tmpl.render(data);
$("#annotations").html(html);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment