Changeset 11570 for main/waeup.kofa/trunk/src/waeup
- Timestamp:
- 3 Apr 2014, 12:53:11 (11 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/browser.py
r11482 r11570 683 683 684 684 def update(self): 685 success,msg, log = self.context.approveApplicantPayment()685 msg, log = self.context.approveApplicantPayment() 686 686 if log is not None: 687 687 applicant = self.context.__parent__ -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/payment.py
r10914 r11570 49 49 except InvalidTransitionError: 50 50 msg = log = 'Error: %s' % sys.exc_info()[1] 51 return False,msg, log51 return msg, log 52 52 log = 'payment approved: %s' % self.p_id 53 53 msg = _('Payment approved') 54 return False,msg, log54 return msg, log 55 55 56 56 def doAfterApplicantPayment(self): … … 62 62 except InvalidTransitionError: 63 63 msg = log = 'Error: %s' % sys.exc_info()[1] 64 return False,msg, log64 return msg, log 65 65 log = 'successful payment: %s' % self.p_id 66 66 msg = _('Successful payment') 67 return False,msg, log67 return msg, log 68 68 69 69 def approveApplicantPayment(self): … … 71 71 """ 72 72 if self.p_state == 'paid': 73 return False,_('This ticket has already been paid.'), None73 return _('This ticket has already been paid.'), None 74 74 self.approve() 75 75 return self.doAfterApplicantPaymentApproval() -
main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
r11567 r11570 1856 1856 1857 1857 def update(self): 1858 success,msg, log = self.context.approveStudentPayment()1858 msg, log = self.context.approveStudentPayment() 1859 1859 if log is not None: 1860 1860 # Add log message to students.log -
main/waeup.kofa/trunk/src/waeup/kofa/students/payments.py
r10906 r11570 107 107 error = self._createActivationCodes() 108 108 if error is not None: 109 return False,error, error109 return error, error 110 110 log = 'successful %s payment: %s' % (self.p_category, self.p_id) 111 111 msg = _('Successful payment') 112 return True,msg, log112 return msg, log 113 113 114 114 def doAfterStudentPaymentApproval(self): … … 118 118 error = self._createActivationCodes() 119 119 if error is not None: 120 return False,error, error120 return error, error 121 121 log = '%s payment approved: %s' % (self.p_category, self.p_id) 122 122 msg = _('Payment approved') 123 return True,msg, log123 return msg, log 124 124 125 125 def approveStudentPayment(self): … … 127 127 """ 128 128 if self.p_state == 'paid': 129 return False,_('This ticket has already been paid.'), None129 return _('This ticket has already been paid.'), None 130 130 self.approve() 131 131 return self.doAfterStudentPaymentApproval()
Note: See TracChangeset for help on using the changeset viewer.