Ignore:
Timestamp:
26 Apr 2011, 10:35:52 (14 years ago)
Author:
Henrik Bettermann
Message:

Implement a vocabulary module in university and move some vocabularies to it.

Rebuild the certificatepage page template.

Rename Course Reference to Course Referrer. It's very difficult to find a proper name for these 'certificatecourse' objects. But we have to clearly distinguish courses and referrers of courses as they are not the same.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/browser/templates/certificatepage.pt

    r5946 r5977  
    11<h2 tal:content="context/title">TITLE</h2>
    22
    3 <table class="listing">
     3<table class="zebra">
    44  <thead>
    55  </thead>
    66  <tbody>
    7     <tr class="odd">
     7    <tr>
    88      <td>Code:</td>
    99      <td tal:content="context/__name__">CODE</td>
    1010    </tr>   
    11     <tr class="even">
     11    <tr>
    1212      <td>Title:</td>
    1313      <td tal:content="context/title">THE TITLE</td>
    1414    </tr>
    15     <tr class="odd">
     15    <tr>
    1616      <td>Start Level:</td>
    1717      <td tal:content="context/start_level">START_LEVEL</td>
    1818    </tr>
    19     <tr class="even">
     19    <tr>
    2020      <td>End Level:</td>
    2121      <td tal:content="context/end_level">END_LEVEL</td>
    2222    </tr>
    23     <tr class="odd">
     23    <tr>
    2424      <td>Study Mode:</td>
    2525      <td tal:content="context/study_mode">STUDY_MODE</td>
    2626    </tr>
    27     <tr class="even">
     27    <tr>
    2828      <td>Application Category:</td>
    2929      <td tal:content="context/application_category">APPLICATION_CATEGORY</td>
     
    3232</table>
    3333
    34 <h3>Courses</h3>
     34<h3><span tal:content="context/__name__">Code</span> Course Referrers</h3>
    3535
     36    <table class="zebra">
     37      <thead>
     38        <tr>
     39          <th>Course Referrer</th>
     40          <th>Course</th>
     41          <th>Title</th>
     42          <th>Level</th>
     43          <th>Semester</th>
     44          <th>Mandatory</th>
     45          <th>&nbsp;</th>
     46        </tr>     
     47      </thead>   
     48      <tbody>
     49      <span tal:omit-tag="" tal:repeat="level python: sorted(view.getCourseList().items())">
     50      <span tal:omit-tag="" tal:repeat="semester python: sorted(level[1].items())">
     51      <tr tal:repeat="courseref python:semester[1]">
     52        <td> <a href="" tal:attributes="href courseref/url" tal:content="courseref/code">courseref code</a></td>
     53        <td> <a href="" tal:attributes="href courseref/course_url" tal:content="courseref/course/code">course code</a></td>
     54        <td tal:content="courseref/title">title</td>
     55        <td tal:content="python:level[0]">level</td>
     56        <td tal:content="python:semester[0]">semester</td>
     57        <td tal:content="courseref/mandatory">mandatory</td>
     58        <td>
     59            <form method="POST">
     60              <input type="hidden" name="code"
     61                 value="" tal:attributes="value courseref/course/code" />
     62              <input type="hidden" name="level"
     63                 value="" tal:attributes="value python:level[0]" />
     64              <input type="submit" name="delcourse" value="delete" />
     65             </form>       
     66        </td>
     67      </tr>
     68      </span>
     69      </span>
     70      </tbody>
     71    </table>
    3672
    37 <div tal:repeat="level python: sorted(view.getCourseList().items())">
    38   <b>
    39     Level <span tal:replace="python: level[0]">100</span>
    40   </b>
    41 
    42   <div tal:repeat="semester python: sorted(level[1].items())">
    43     <div tal:condition="python: semester[0] == '0'">
    44       &nbsp;&nbsp;Untimed courses
    45     </div>
    46     <div tal:condition="python: semester[0] == '1'">
    47       &nbsp;&nbsp;First semester
    48     </div>
    49     <div tal:condition="python: semester[0] == '2'">
    50       &nbsp;&nbsp;Second semester
    51     </div>
    52     <div tal:condition="python: semester[0] == '3'">
    53       &nbsp;&nbsp;Combined
    54     </div>
    55    
    56     <div tal:repeat="course python:semester[1]">
    57       &nbsp;&nbsp;&nbsp;&nbsp;
    58         <form method="POST">
    59           <input type="hidden" name="code"
    60                  value="" tal:attributes="value course/code" />
    61           <input type="hidden" name="level"
    62                  value="" tal:attributes="value python:level[0]" />
    63           <input type="submit" name="delcourse" value="delete" />
    64 
    65       <a href=""
    66          tal:attributes="href course/url"
    67          ><span tal:content="course/code">code</span>
    68       </a>
    69       <span tal:content="course/title">title</span>
    70       <span tal:condition="course/mandatory">
    71         [mandatory]
    72       </span>
    73       <span tal:condition="not: course/mandatory">
    74         [optional]
    75       </span>
    76         </form>
    77     </div>
    78   </div>
    79 
    80 </div>
    81 
    82 
Note: See TracChangeset for help on using the changeset viewer.