forked from qmd-lab/course-website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
schedule.ejs
42 lines (37 loc) · 954 Bytes
/
schedule.ejs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
```{=html}
<% for (const week of items) { %>
<h4>Week <%= week.week %></h4>
<div class="week-x-box">
<div class="daily-sched">
<% for (const day of week.days) { %>
<div class="date-cell">
<p><%= day['display-date'] %></p>
</div>
<div class="materials-cell">
<p><span class="daily-topic"><%= day.topic %></span><br>
<% if (day.items && day.items.length > 0) { %>
<% for (const item of day.items) { %>
<% if (item.render){ %>
<a href="<%= item.href %>" class="btn btn-success btn-sm"><%= item.type %></a>
<% } %>
<% } %>
<% } %>
</p>
</div>
<% } %>
</div>
<div class="resources">
<p><span">Resources</span></p>
<ul>
<% if (week.resources && week.resources.length > 0) { %>
<% for (const item of week.resources) { %>
<li><%= item %></li>
<% } %>
<% } else { %>
<li>None this week</li>
<% } %>
</ul>
</div>
</div>
<% } %>
```