Changeset 2656 for WAeUP_SRP/base/skins
- Timestamp:
- 14 Nov 2007, 21:28:30 (17 years ago)
- Location:
- WAeUP_SRP/base/skins
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/base/skins/waeup_accommodation/getAccommodationInfo.py
r2454 r2656 64 64 info['email']=s_brain.email 65 65 info['level']=s_brain.level 66 info['verdict']=getattr(s_brain, "verdict","N/A")66 info['verdict']=getattr(s_brain,'verdict','') 67 67 68 68 … … 90 90 info['acco'] = None 91 91 return info 92 info['session'] = session = context.getSessionId() 92 info['session'] = session = context.getSessionId() 93 93 acco_id = 'accommodation_' + session[0] 94 94 acco = getattr(student,acco_id,None) -
WAeUP_SRP/base/skins/waeup_epayment/approve_epayment.py
r1568 r2656 30 30 student = getattr(students,student_id) 31 31 32 s_brain = context.students_catalog(id=student_id)[0] 33 session = s_brain.session 34 35 next_info = context.getNextInfo(s_brain) 36 next_session_id = next_info['next_session_id'] 37 next_session_str = next_info['next_session_str'] 38 next_level_id = next_info['next_level_id'] 39 next_transition = next_info['next_transition'] 40 next_verdict = next_info['next_verdict'] 41 32 42 pd = {} 33 43 #from Products.zdb import set_trace;set_trace() … … 39 49 pd['resp_desc'] = 'Payment approved by %s, %s' % (member,DateTime.DateTime()) 40 50 doc.edit(mapping=pd) 51 41 52 if doc.type_description.startswith('School Fee'): 42 wftool.doActionFor(student,'pay_school_fee') 53 study_course = getattr(student,'study_course') 54 try: 55 wftool.doActionFor(study_course,'open') 56 except: 57 pass 58 verdict = s_brain.verdict 59 if verdict == 'N/A': 60 verdict = '' 61 study_course.getContent().edit(mapping= {'current_level': next_level_id, 62 'current_session': next_session_id, 63 'current_verdict': next_verdict, 64 'previous_verdict': verdict, 65 }) 66 if next_transition: 67 wftool.doActionFor(student,next_transition) 68 43 69 logger.info('%s approves epayment for %s' % (member,student_id)) 44 70 wftool.doActionFor(context,'close') -
WAeUP_SRP/base/skins/waeup_student/getNextInfo.py
r2652 r2656 42 42 info['next_session_id'] = next_session_id = "%02d" % (int(session_id)+1) 43 43 if int(session_id) > 4: 44 info['next_transition'] = "pay_school_fee"45 44 info['next_verdict'] = '' 46 45 if verdict in ('A','B',): … … 48 47 else: 49 48 info['next_level_id'] = level_id 49 if int(session_id) > int(context.getSessionId()[0]) -2: 50 info['next_transition'] = "pay_school_fee" 50 51 else: 51 52 info['next_level_id'] = "%s" % (int(level_id) + 100)
Note: See TracChangeset for help on using the changeset viewer.