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

« back to all changes in this revision

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

  • Committer: stevenbird
  • Date: 2007-12-05 22:41:05 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:7
GPL license

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<html xmlns="http://www.w3.org/1999/xhtml"
2
 
      xmlns:py="http://genshi.edgewall.org/">
3
 
  <head>
4
 
    <title>${context.subject.name} (${context.semester.year} semester ${context.semester.semester})</title>
5
 
  </head>
6
 
  <body>
7
 
    <h1>${context.subject.name}</h1>
8
 
    <div id="ivle_padding">
9
 
      <div class="contextactions">
10
 
        <a py:if="'enrol' in permissions"
11
 
           class="groupaction"
12
 
           href="${req.publisher.generate(context, None, ('+enrolments', '+new'))}">
13
 
          Enrol users
14
 
        </a>
15
 
      </div>
16
 
 
17
 
      <div py:if="'edit' in permissions or context.projects.count() > 0"
18
 
           class="majorsection">
19
 
        <h2>Projects</h2>
20
 
        <py:choose test="context.projects.count()">
21
 
          <p py:when="0">
22
 
            There are no projects for this offering.
23
 
          </p>
24
 
          <py:otherwise>
25
 
            <ul class="paddedlist">
26
 
              <li py:for="project in context.projects"
27
 
                  py:attrs="{'class': 'project closed'}
28
 
                            if project.has_deadline_passed(req.user)
29
 
                            else {'class': 'project'}"
30
 
                  py:with="principal = project.project_set.get_submission_principal(req.user)">
31
 
                <a href="${project.url}">${project.name}</a> &ndash;
32
 
                <span py:content="format_submission_principal(req.user, principal)" /> &ndash;
33
 
                <span title="${format_datetime(project.deadline)}">
34
 
                  ${'closed' if project.has_deadline_passed(req.user) else 'due'} ${format_datetime_short(project.deadline)}
35
 
                </span>
36
 
                <py:if test="principal is not None"
37
 
                       py:with="submissions = project.get_submissions_for_principal(principal)">
38
 
                  &ndash;
39
 
                  <py:choose test="submissions.count()">
40
 
                    <span py:when="0">
41
 
                      not yet submitted
42
 
                    </span>
43
 
                    <span py:otherwise=""
44
 
                          py:with="latest = submissions.last()"
45
 
                          title="${format_datetime(latest.date_submitted)}">
46
 
                      last submitted ${format_datetime_short(latest.date_submitted)}
47
 
                    </span>
48
 
                  </py:choose>
49
 
                </py:if>
50
 
                <br />
51
 
                ${project.synopsis}
52
 
              </li>
53
 
            </ul>
54
 
            <py:if test="context.get_open_projects_for_user(req.user).count() > 0">
55
 
              <p>
56
 
                To submit to a project that has not yet closed, use the file
57
 
                browser to navigate to the file or directory that you wish to
58
 
                submit, click &ldquo;More actions...&rdquo;,
59
 
                &ldquo;Submit&rdquo;, and then select the correct project.
60
 
              </p>
61
 
              <p>
62
 
                If the project to which you intend to submit is not listed,
63
 
                ensure that you are in the correct directory, or a subdirectory
64
 
                thereof. For solo projects, you must be inside the subject's
65
 
                &ldquo;mywork&rdquo; directory. For group projects, you must be
66
 
                inside the directory for the assigned group.
67
 
              </p>
68
 
              <p>
69
 
                You may resubmit a project as you wish until the deadline, but
70
 
                a new submission will overwrite any made earlier.
71
 
              </p>
72
 
            </py:if>
73
 
          </py:otherwise>
74
 
        </py:choose>
75
 
 
76
 
        <a py:if="'edit' in permissions"
77
 
           class="manageaction"
78
 
           href="${req.publisher.generate(context, None, '+projects')}">
79
 
          Manage projects
80
 
        </a>
81
 
      </div>
82
 
 
83
 
      <div py:if="'edit' in permissions or context.worksheets.count() > 0"
84
 
           class="majorsection">
85
 
        <h2>Worksheets</h2>
86
 
        <py:choose test="context.worksheets.count()">
87
 
          <p py:when="0">
88
 
            There are no worksheets for this offering.
89
 
            <a class="addaction" href="${req.publisher.generate(context, None, ('+worksheets', '+new'))}">Create one now</a>
90
 
          </p>
91
 
          <div py:otherwise="">
92
 
            <a py:if="'edit' in permissions"
93
 
               class="manageaction"
94
 
               href="${req.publisher.generate(context, None, ('+worksheets', '+edit'))}">
95
 
              Manage worksheets
96
 
            </a>
97
 
          </div>
98
 
        </py:choose>
99
 
      </div>
100
 
    </div>
101
 
  </body>
102
 
</html>
103
 
    
104