2018-08-23 11:43:42 +02:00
|
|
|
<?lua
|
2018-08-23 15:22:59 +02:00
|
|
|
if not data then return end
|
2018-10-19 11:20:56 +02:00
|
|
|
local active = "_active"
|
2018-08-23 15:22:59 +02:00
|
|
|
for k,v in pairs(data) do
|
|
|
|
if v.children then
|
|
|
|
?>
|
2018-10-19 11:20:56 +02:00
|
|
|
<div class="container<?=active?>" id =<?='"toc'..v.id..'"'?>>
|
2018-08-23 15:22:59 +02:00
|
|
|
<h1><?=v.name:gsub("^%d+%.","")?></h1>
|
|
|
|
<?lua
|
2018-10-19 11:20:56 +02:00
|
|
|
active = ''
|
2018-08-23 15:22:59 +02:00
|
|
|
for l,child in pairs(v.children) do
|
|
|
|
?>
|
|
|
|
<div class="sub-container">
|
|
|
|
<h2><?=child.name:gsub("^%d+%.","")?></h2>
|
|
|
|
<?lua
|
|
|
|
if child.sections then
|
|
|
|
for m, entry in pairs(child.sections) do
|
|
|
|
?>
|
|
|
|
<div class= "entry">
|
|
|
|
<p>
|
|
|
|
<?lua if entry.title ~= "" then ?>
|
|
|
|
<span class= "fa fa-bookmark"></span>
|
|
|
|
<span class= "title"><?=entry.title?></span>
|
|
|
|
<?lua end ?>
|
|
|
|
<span class= "title-optional"></span>
|
|
|
|
<span class="location"><?=entry.location?></span>
|
|
|
|
</p>
|
|
|
|
<div class="entry-short-des">
|
|
|
|
<span><?=entry.subtitle?></span>
|
|
|
|
<span class="date">
|
|
|
|
<?lua
|
2023-04-26 18:51:03 +02:00
|
|
|
if tostring(entry["start"]):match("^20%d.*") and tostring(entry['end']):match("^20%d.*") then
|
|
|
|
echo("%d-%d",entry["start"],entry['end'])
|
2018-08-23 15:22:59 +02:00
|
|
|
end
|
|
|
|
?>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
<div class="entry-description">
|
|
|
|
<?=entry.content?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<?lua
|
|
|
|
end
|
|
|
|
end
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
<?lua
|
|
|
|
end
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
<?lua
|
|
|
|
else
|
|
|
|
?>
|
2018-10-19 11:20:56 +02:00
|
|
|
<div class="container<?=active?>" id =<?='"toc'..v.id..'"'?>>
|
2018-08-23 15:22:59 +02:00
|
|
|
<h1><?=v.name?></h1>
|
|
|
|
<?lua
|
2018-10-19 11:20:56 +02:00
|
|
|
active = ''
|
2018-08-23 15:22:59 +02:00
|
|
|
if v.sections then
|
|
|
|
for m, entry in pairs(v.sections) do
|
|
|
|
?>
|
|
|
|
<div class= "entry">
|
|
|
|
<p>
|
|
|
|
<?lua if entry.title ~= "" then ?>
|
|
|
|
<span class= "fa fa-bookmark"></span>
|
|
|
|
<span class= "title"><?=entry.title?></span>
|
|
|
|
<?lua end ?>
|
|
|
|
<span class= "title-optional"></span>
|
|
|
|
<span class="location"><?=entry.location?></span>
|
|
|
|
</p>
|
|
|
|
<div class="entry-short-des">
|
|
|
|
<span><?=entry.subtitle?></span>
|
|
|
|
<span class="date">
|
|
|
|
<?lua
|
2023-04-26 18:51:03 +02:00
|
|
|
if tostring(entry["start"]):match("^20%d.*") and tostring(entry['end']):match("^20%d.*") then
|
|
|
|
echo("%d-%d",entry["start"],entry['end'])
|
2018-08-23 15:22:59 +02:00
|
|
|
end
|
|
|
|
?>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
<div class="entry-description">
|
|
|
|
<?=entry.content?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<?lua
|
|
|
|
end
|
|
|
|
end
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
<?lua
|
|
|
|
end
|
|
|
|
end
|
2018-08-23 11:43:42 +02:00
|
|
|
?>
|