Changeset 2469 for WAeUP_SRP


Ignore:
Timestamp:
29 Oct 2007, 09:04:16 (17 years ago)
Author:
joachim
Message:

add max_credits again, got lost somehow

File:
1 edited

Legend:

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

    r2466 r2469  
    9797credits_total,carry_overs,normal = course_results.getCourses(student_id,level_id)
    9898info['credits_total'] = credits_total
    99 info['credits_exceeded'] = credits_total > 51
     99max_credits = 50
     100if context.getId() == student.end_level:
     101    max_credits = 51
     102info['max_credits'] = max_credits
     103info['credits_exceeded'] = credits_total > max_credits
    100104current_session = student.session
    101 info['submission_allowed']= not info['credits_exceeded'] and current_session == context.getSessionId()[0]
     105info['submission_allowed']= not info['credits_exceeded'] and\
     106    current_session == context.getSessionId()[0]
    102107# carry_overs.sort(cmp_semester_id)
    103108info['carry_overs'] = carry_overs
Note: See TracChangeset for help on using the changeset viewer.