Ignore:
Timestamp:
9 Nov 2007, 21:30:03 (17 years ago)
Author:
Henrik Bettermann
Message:

display semesters seperately: first, second and combined

Location:
WAeUP_SRP/base/skins/waeup_student
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/base/skins/waeup_student/getStudyLevelInfo.py

    r2606 r2614  
    3737import logging
    3838logger = logging.getLogger('Skins.getStudyLevelInfo')
    39 
    40 #def calculateGPA():
    41 #    """calculate the gpa"""
    42 #    sum = 0
    43 #    course_count = 0
    44 #    for sc in context.objectValues():
    45 #        result = sc.getContent()
    46 #        if not result.grade:
    47 #            continue
    48 #        res = context.portal_catalog({'meta_type': 'Course',
    49 #                                      'id': sc.aq_parent.id})
    50 #        if len(res) < 1:
    51 #            continue
    52 #        course = res[0].getObject().getContent()
    53 #    if course_count:
    54 #        return sum/course_count
    55 #    return 0.0
    56 
    57 #def cmp_semester_id(a,b):
    58 #    s1 = "%(semester)s%(id)s" % a
    59 #    s2 = "%(semester)s%(id)s" % b
    60 #    if s1 == s2:
    61 #        return 0
    62 #    if s1 > s2:
    63 #        return 1
    64 #    return -1
    6539
    6640student_id = context.getStudentId()
  • WAeUP_SRP/base/skins/waeup_student/study_level_view.pt

    r2606 r2614  
    7777        <span tal:repeat="sem python:('1','2')">       
    7878                   
    79         <th colspan="3" tal:content="python: test(sem == '1','First Semester', 'Second Semester')" />               
     79        <tr><th colspan="3" tal:content="python: test(sem == '1','First Semester', 'Second Semester')" /></tr>               
    8080        <tr tal:repeat="row python: test(sem == '1',info['normal1'],info['normal2'])"
    8181            tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')">
     
    103103          </td>         
    104104        </tr>
    105        
    106        
    107         <th colspan="3" tal:condition="info/normal3"> Combined</th>               
     105
     106        </span>       
     107       
     108        <tr><th colspan="3" tal:condition="info/normal3"> Combined</th></tr>               
    108109        <tr tal:condition="info/normal3" tal:repeat="row info/normal3"
    109110            tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')">
     
    134135       
    135136       
    136         </span>
     137
    137138
    138139        <tr>
Note: See TracChangeset for help on using the changeset viewer.