-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcourses.html
More file actions
33 lines (33 loc) · 876 Bytes
/
Copy pathcourses.html
File metadata and controls
33 lines (33 loc) · 876 Bytes
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
{% extends "base.html" %}
{% block content %}
<h2>Available Courses</h2>
<table>
<thead>
<tr>
<th>Code</th>
<th>Title</th>
<th>Credits</th>
<th>Status</th>
</tr>
</thead>
<tbody>
{% for c in courses %}
<tr>
<td>{{ c.code }}</td>
<td>{{ c.title }}</td>
<td>{{ c.credits }}</td>
<td>
{% if c.is_enrolled %}
<span class="tag">Enrolled</span>
{% else %}
<form method="post" style="display:inline;">
<input type="hidden" name="course_id" value="{{ c.id }}">
<button type="submit" class="btn small">Register</button>
</form>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}