Changeset 8453 for main/waeup.kofa/trunk/src/waeup/kofa
- Timestamp:
- 15 May 2012, 20:29:34 (13 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/applicants/interfaces.py
r8422 r8453 523 523 """ 524 524 525 def doAfterApplicantPaymentApproval(): 526 """Process applicant after payment was approved. 527 528 """ 529 525 530 def approveApplicantPayment(): 526 531 """Approve payment and process applicant. -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/payment.py
r8434 r8453 40 40 return 41 41 42 def doAfterApplicantPaymentApproval(self): 43 """Process applicant after payment was approved. 44 """ 45 wf_info = IWorkflowInfo(self.__parent__) 46 try: 47 wf_info.fireTransition('approve') 48 except InvalidTransitionError: 49 msg = log = 'Error: %s' % sys.exc_info()[1] 50 return False, msg, log 51 log = 'payment approved: %s' % self.p_id 52 msg = _('Payment approved') 53 return False, msg, log 54 42 55 def doAfterApplicantPayment(self): 43 56 """Process applicant after payment was made. … … 45 58 wf_info = IWorkflowInfo(self.__parent__) 46 59 try: 47 wf_info.fireTransition(' approve')60 wf_info.fireTransition('pay') 48 61 except InvalidTransitionError: 49 62 msg = log = 'Error: %s' % sys.exc_info()[1] … … 59 72 return False, _('This ticket has already been paid.'), None 60 73 self.approve() 61 return self.doAfterApplicantPayment ()74 return self.doAfterApplicantPaymentApproval() 62 75 63 76 ApplicantOnlinePayment = attrs_to_fields(ApplicantOnlinePayment) -
main/waeup.kofa/trunk/src/waeup/kofa/students/interfaces.py
r8422 r8453 515 515 """ 516 516 517 def doAfterStudentPaymentApproval(): 518 """Process student after payment was approved. 519 520 """ 521 517 522 def approveStudentPayment(): 518 523 """Approve payment and process student. -
main/waeup.kofa/trunk/src/waeup/kofa/students/payments.py
r8428 r8453 89 89 return True, msg, log 90 90 91 def doAfterStudentPaymentApproval(self): 92 """Process student after payment was approved. 93 """ 94 student = self.getStudent() 95 if self.p_category == 'clearance': 96 # Create CLR access code 97 pin, error = create_accesscode( 98 'CLR',0,self.amount_auth,student.student_id) 99 if error: 100 return False, error, error 101 self.ac = pin 102 elif self.p_category == 'schoolfee': 103 # Create SFE access code 104 pin, error = create_accesscode( 105 'SFE',0,self.amount_auth,student.student_id) 106 if error: 107 return False, error, error 108 self.ac = pin 109 elif self.p_category == 'bed_allocation': 110 # Create HOS access code 111 pin, error = create_accesscode( 112 'HOS',0,self.amount_auth,student.student_id) 113 if error: 114 return False, error, error 115 self.ac = pin 116 log = 'payment approved: %s' % self.p_id 117 msg = _('Payment approved') 118 return True, msg, log 119 91 120 def approveStudentPayment(self): 92 121 """Approve payment and process student.
Note: See TracChangeset for help on using the changeset viewer.