Changeset 14601 for main


Ignore:
Timestamp:
6 Mar 2017, 10:09:13 (8 years ago)
Author:
Henrik Bettermann
Message:

Some universities may add further conditions to exclude
students from reports. These conditions can be customized in
excluded function.

Location:
main/waeup.kofa/trunk/src/waeup/kofa/students/reports
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/students/reports/level_report.py

    r14574 r14601  
    4141    creation_dt_string = Attribute('Human readable report creation datetime')
    4242
     43def excluded(level_obj):
     44    """Some universities may add further conditions to exclude
     45    students from reports. These conditions can be customized in
     46    this function.
     47    """
     48    return False
     49
    4350def get_students(faccode, depcode, certcode, session, level):
    4451    """Get students in a certain department, studying a certain programmen
     
    6471        level_obj = stud['studycourse'][str(level)]
    6572        if level_obj.level_session != session:
     73            continue
     74        if excluded(level_obj):
    6675            continue
    6776        passed_params = level_obj.passed_params
  • main/waeup.kofa/trunk/src/waeup/kofa/students/reports/raw_score_report.py

    r14572 r14601  
    4141    certcode = Attribute('Certificate to report')
    4242    creation_dt_string = Attribute('Human readable report creation datetime')
     43
     44def excluded(level_obj):
     45    """Some universities may add further conditions to exclude
     46    students from reports. These conditions can be customized in
     47    this function.
     48    """
     49    return False
    4350
    4451def get_courses(faccode, depcode, certcode, session, level):
     
    8289        level_obj = stud['studycourse'][str(level)]
    8390        if level_obj.level_session != session:
     91            continue
     92        if excluded(level_obj):
    8493            continue
    8594        scores = dict()
  • main/waeup.kofa/trunk/src/waeup/kofa/students/reports/session_results_presentation.py

    r14572 r14601  
    3939    """ Same interface as for level session results presentation.
    4040    """
     41
     42def excluded(level_obj):
     43    """Some universities may add further conditions to exclude
     44    students from reports. These conditions can be customized in
     45    this function.
     46    """
     47    return False
    4148
    4249def get_students(faccode, depcode, certcode, session, level=None):
     
    7279            level_obj = stud['studycourse'][str(level)]
    7380            if level_obj.level_session != session:
     81                continue
     82            if excluded(level_obj):
    7483                continue
    7584        else:
Note: See TracChangeset for help on using the changeset viewer.