4
4
<title>Groups</title>
7
<h1>Groups for ${offering.subject.name}</h1>
7
8
<div id="ivle_padding">
8
<p py:if="not enrolments">Error: You are not currently enrolled in any subjects.</p>
9
<py:for each="enrolment in enrolments">
10
<div id="subject${enrolment.offering.id}" class="subject">
11
<h1>${enrolment.offering.subject.name}</h1>
12
<py:for each="group in get_user_groups(enrolment.offering)">
13
<h2>${group.nick} (${group.name})</h2>
14
<!-- Need proper test (for invite/membership). -->
15
<!-- <py:choose test="group">
16
<py:when test="True"> -->
17
<p>You are a member of this group.</p>
20
<p>You have been invited to this group.</p>
23
onclick="accept("${group.name}")"
26
onclick="decline("${group.name}")"
33
<py:for each="member in group.members">
34
<li>${member.fullname} (${member.login})</li>
40
<py:if test="manage_subjects">
42
<h1>Group Administration</h1>
43
<label for="subject_select">Subject:</label>
44
<select id="subject_select">
45
<py:for each="subject in manage_subjects">
46
<option value="${subject.id}">${subject.name} (${subject.code})</option>
49
<input type="button" value="Manage" onclick="manage_subject()" />
50
<div id="subject_div"></div>
9
<div id="offering_groups" />
11
<script type="text/javascript">
12
manage_subject_offering(${offering.subject.id}, document.getElementById('offering_groups'));