Changeset 1355
- Timestamp:
- 25 Jan 2007, 20:49:22 (18 years ago)
- Location:
- WAeUP_SRP/trunk/skins
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/skins/waeup_default/getReviewInfo.py
r1191 r1355 23 23 if context.portal_type != "Student": 24 24 student_id = context.getStudentId() 25 res = context.portal_catalog(id = student_id,portal_type='Student') 26 if res: 27 s_review = res[-1].review_state 28 return "%s / %s" % (s_review,d_review) 25 if student_id: 26 res = context.portal_catalog(id = student_id,portal_type='Student') 27 if res: 28 s_review = res[-1].review_state 29 return "%s / %s" % (s_review,d_review) 29 30 return "%s" % (d_review) 30 31 -
WAeUP_SRP/trunk/skins/waeup_epayment/pay_online.py
r1348 r1355 21 21 22 22 student_id = context.getStudentId() 23 if student_id is None: 24 return context.REQUEST.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url()) 23 student = getattr(students,student_id) 25 24 26 student = getattr(students,student_id)27 25 sbrain = context.students_catalog(id=student_id)[0] 28 26 amount,description = context.getSchoolFee(sbrain.faculty) … … 50 48 order_id = info['order_id'] = "%d" % int(now.timeTime()*1000) 51 49 info['order_id'] = "%s%s" % (student_id[1:],order_id) 50 p_id = "p%s" % order_id 51 52 if student_id is None: 53 return context.REQUEST.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url()) 54 55 if context.portal_url().find('uniben-demo.waeup.org') >-1 or\ 56 context.portal_url().find('uniben.waeup.org') >-1: 57 info['action'] = "http://www.wemaonlinepayments.biz/payment.aspx" 58 else: 59 return None 60 #info['action'] = "%s/payments/%s/simulate_callback" % (student.absolute_url(),p_id) 61 62 52 63 if "payments" not in student.objectIds(): 53 64 student.invokeFactory('PaymentsFolder','payments') … … 62 73 return context.wema_form(info=info) 63 74 64 p_id = "p%s" % order_id 75 65 76 payments.invokeFactory('Payment', p_id) 66 77 payment = getattr(payments,p_id) … … 73 84 #wftool.doActionFor(student,'pay_school_fee') 74 85 info['callback_url'] = "%s/payments/%s/epayment_cb" % (student.absolute_url(),p_id) 75 if context.portal_url().find('uniben-demo.waeup.org') >-1 or\ 76 context.portal_url().find('uniben.waeup.org') >-1: 77 info['action'] = "http://www.wemaonlinepayments.biz/payment.aspx" 78 else: 79 info['action'] = "%s/payments/%s/simulate_callback" % (student.absolute_url(),p_id) 86 80 87 logger.info('"%(student_id)s","%(type_description)s", "%(amount)s N"' % info) 81 88 payment_fields = (('x_SiteID','site_id'),
Note: See TracChangeset for help on using the changeset viewer.