- Timestamp:
- 8 May 2007, 20:43:37 (18 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 1 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/WAeUPTool.py
r1756 r1758 740 740 d['sex'] = dict.get('sex') == 'F' 741 741 sub_doc.edit(mapping = d) 742 self.portal_workflow.doActionFor(sub_obj,f2t[pt]['wf_state'],dest_container=sub_obj) 742 new_state = f2t[pt]['wf_state'] 743 if new_state != "remain": 744 self.portal_workflow.doActionFor(sub_obj,new_state,dest_container=sub_obj) 743 745 wfaction = 'return' 744 746 self.portal_workflow.doActionFor(student_obj,wfaction) -
WAeUP_SRP/trunk/skins/waeup_default/sessions_voc.py
r1756 r1758 15 15 except: 16 16 return 'unknown' 17 ##if len(key) != 2:18 ## return 'unknown'19 17 if y < 90: 20 18 cent = 2000 -
WAeUP_SRP/trunk/skins/waeup_epayment/getPaymentsFolderInfo.py
r1661 r1758 39 39 is_so = info['is_so'] = context.isSectionOfficer() 40 40 41 res = context.portal_catalog(portal_type='Student',id = student_id) 42 if res: 43 info['review_state'] = res[0].review_state 41 #res = context.portal_catalog(portal_type='Student',id = student_id) 42 #res = context.students_catalog(id = student_id) 43 info['review_state'] = s_brain.review_state 44 session = s_brain.session 45 info['next_session'], info['next_session_str'] = context.getNextSessionId(session) 44 46 45 47 info['student_name'] = s_brain.name -
WAeUP_SRP/trunk/skins/waeup_epayment/pay_by_sc.py
r1568 r1758 16 16 logger = logging.getLogger('Skins.pay_by_sc') 17 17 import DateTime 18 try: 19 from Products.zdb import set_trace 20 except: 21 def set_trace(): 22 pass 18 23 19 24 if context.portal_membership.isAnonymousUser(): … … 28 33 29 34 student = getattr(students,student_id) 30 sbrain = context.students_catalog(id=student_id)[0] 31 amount,description = context.getSchoolFee(sbrain.faculty) 32 35 s_brain = context.students_catalog(id=student_id)[0] 36 session = s_brain.session 37 next_session, next_session_str = context.getNextSessionId(session) 38 amount,description = context.getSchoolFee(s_brain.faculty) 33 39 validate = request.has_key("cpsdocument_create_button") 34 40 res,psm,ds = lt.renderLayout(layout_id= 'student_schoolfee', … … 46 52 psm = psm, 47 53 mode = 'edit', 54 next_session_str = next_session_str, 48 55 ds = ds, 49 56 ) … … 52 59 psm = None, 53 60 mode = 'edit', 61 next_session_str = next_session_str, 54 62 ds = ds, 55 63 ) … … 73 81 info['date'] = now 74 82 info['amount'] = "n/a" 75 pin = info['order_id'] = ds.get('pin')83 pin = info['order_id'] = "%s__%s" % (ds.get('pin'),next_session) 76 84 info['type_code'] = "%s" % pin 77 info['type_description'] = 'School Fee for Session 2006/2007'85 info['type_description'] = 'School Fee for Session %s' % next_session_str 78 86 info['resp_code'] = "SC" 79 87 info['resp_desc'] = "SC Payment Successful" … … 84 92 payment.getContent().edit(mapping=info) 85 93 wftool.doActionFor(payment,'close') 86 wftool.doActionFor(student,'pay_school_fee') 94 if next_session == context.getSessionId(): 95 wftool.doActionFor(student,'pay_school_fee') 96 else: 97 study_course = getattr(student,'study_course') 98 wftool.doActionFor(study_course,'open') 99 study_course_doc = study_course.getContent() 100 next_level = "%s" % (int(s_brain.level) + 100) 101 study_course_doc.edit(mapping= {'current_level': next_level, 102 'current_session': next_session,}) 87 103 logger.info('%s paid school fee by scratch card' % student_id) 88 104 else: -
WAeUP_SRP/trunk/skins/waeup_epayment/pay_by_sc_form.pt
r1378 r1758 13 13 </metal:block> 14 14 <metal:block fill-slot="main"> 15 <h3>Pay Your 2006/2007School Fee by Scratch Card!</h3>15 <h3>Pay Your <span tal:replace="options/next_session_str" /> School Fee by Scratch Card!</h3> 16 16 <br /> 17 17 <div tal:replace="structure rendered_main" /> -
WAeUP_SRP/trunk/skins/waeup_epayment/payments_view.pt
r1636 r1758 69 69 <form tal:condition="python:review_state == 'returning'" 70 70 tal:attributes="action string: ${context/absolute_url}/pay_by_sc" method="post" class="group"> 71 <input type="hidden" name="paid_session" 72 tal:attributes="value info/next_session" 73 /> 74 71 75 <input type="submit" name="epayment" 72 76 class="context" 73 value="Pay School Fee by Scratch Card" 77 value="Pay School Fee by Scratch Card" 78 tal:attributes="value string:Pay ${info/next_session_str} School Fee by Scratch Card" 74 79 /> 75 80 </form> -
WAeUP_SRP/trunk/skins/waeup_student/getSchoolFeePrefix.py
r1571 r1758 16 16 return None 17 17 18 try: 19 from Products.zdb import set_trace 20 except: 21 def set_trace(): 22 pass 18 23 import logging 19 24 logger = logging.getLogger('Skins.getSchoolFeePrefix') … … 23 28 res = context.portal_catalog(portal_type="Certificate", 24 29 id = sbrain.course) 30 #set_trace() 25 31 if not res: 26 32 logger.info('%s, certificate %s not found' % (student_id,course))
Note: See TracChangeset for help on using the changeset viewer.