Changeset 2451 for WAeUP_SRP


Ignore:
Timestamp:
27 Oct 2007, 14:26:41 (17 years ago)
Author:
joachim
Message:

new getNextInfo used in pay_by_sc

Location:
WAeUP_SRP/base/skins
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/base/skins/waeup_epayment/pay_by_sc.py

    r2153 r2451  
    3434student = getattr(students,student_id)
    3535s_brain = context.students_catalog(id=student_id)[0]
    36 session = s_brain.session
    37 next_session, next_session_str = context.getNextSessionId(session)
    38 validate = request.has_key("cpsdocument_create_button")
     36next_info = context.getNextInfo(s_brain)
     37next_session_id = next_info['next_session_id']
     38next_session_str = next_info['next_session_str']
     39next_level_id = next_info['next_level_id']
     40next_transition = next_info['next_transition']
     41study_course = getattr(student,'study_course')
     42study_course.getContent().edit(mapping= {'current_level': next_level_id,
     43                                         'current_session': next_session_id,})
     44if next_transition:
     45    wftool.doActionFor(student,next_transition)
     46
     47# session = s_brain.session
     48# next_session, next_session_str = context.getNextSessionId(session)
     49# validate = request.has_key("cpsdocument_create_button")
    3950res,psm,ds = lt.renderLayout(layout_id= 'student_schoolfee',
    4051                      schema_id= 'payment',
  • WAeUP_SRP/base/skins/waeup_student/add_course_result.py

    r2448 r2451  
    7171d['student_id'] = student_id = context.getStudentId()
    7272d['level_id'] = level_id = context.getId()
    73 d['session_id'] = context.session
     73session_id = context.getLevelSession(context.getContent(),student_id,level_id)
     74d['session_id'] = session_id
    7475d['key'] = "%s|%s|%s" % (student_id,level_id,course_id)
    7576
  • WAeUP_SRP/base/skins/waeup_student/getLevelSession.py

    r2439 r2451  
    1212return fixed session_id from level
    1313"""
     14import logging
     15logger = logging.getLogger('Skins.getLevelSession')
    1416session_id = level_doc.session
    1517changed = False
  • WAeUP_SRP/base/skins/waeup_student/getStudyLevelInfo.py

    r2448 r2451  
    3232course_results = context.course_results
    3333request = context.REQUEST
    34 #session = request.SESSION
    3534response = request.RESPONSE
    3635import logging
     
    110109
    111110return info
    112 
Note: See TracChangeset for help on using the changeset viewer.