~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/admin/templates/subjects.html

  • Committer: William Grant
  • Date: 2009-07-30 10:29:38 UTC
  • Revision ID: grantw@unimelb.edu.au-20090730102938-o9d2f6hn0o96lc0u
Clean up the new tablesque console.

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
    <h1>Subjects</h1>
9
9
    <div id="ivle_padding">
10
10
      <p py:if="len(semesters) == 0">You are not currently enrolled in any subjects.</p>
11
 
      <py:for each="(semester, offerings) in semesters">
12
 
        <h2 py:attrs="{'class': 'subject_current' if semester.state == u'current' else None}">
13
 
          ${semester.year}, semester ${semester.semester}
14
 
        </h2>
 
11
      <py:for each="(semester, enrolments) in semesters">
 
12
        <py:choose test="semester.state">
 
13
          <h2 py:when="u'current'">${semester.year}, semester ${semester.semester}</h2>
 
14
          <h3 py:otherwise="">${semester.year}, semester ${semester.semester}</h3>
 
15
        </py:choose>
15
16
        <ul>
16
 
          <py:for each="offering in offerings">
 
17
          <py:for each="enrolment in enrolments">
17
18
            <li>
18
 
              <a href="${offering_url(offering)}/+worksheets">${offering.subject.name}</a>
19
 
              <py:if test="'edit' in offering.get_permissions(user)">
 
19
              <a href="${offering_url(enrolment.offering)}/+worksheets">${enrolment.offering.subject.name}</a>
 
20
              <py:if test="'edit' in enrolment.offering.get_permissions(user)">
20
21
                -
21
 
                <a href="${offering_url(offering)}/+projects">(administer projects)</a>
22
 
                <py:if test="'enrol' in offering.get_permissions(user)">
23
 
                  <a href="${offering_url(offering)}/+enrolments/+new">(enrol users)</a>
24
 
                </py:if>
 
22
                <a href="${offering_url(enrolment.offering)}/+projects">(administer projects)</a>
 
23
                <a href="${offering_url(enrolment.offering)}/+enrolments/+new">(enrol users)</a>
25
24
              </py:if>
26
25
            </li>
27
26
          </py:for>