Changeset 9153 for main/waeup.fceokene/trunk/src/waeup/fceokene/students
- Timestamp:
- 4 Sep 2012, 07:07:13 (12 years ago)
- Location:
- main/waeup.fceokene/trunk/src/waeup/fceokene/students
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.fceokene/trunk/src/waeup/fceokene/students/interfaces.py
r8868 r9153 71 71 """ 72 72 73 p_current = schema.Bool( 74 title = _(u'Current Session Payment'), 75 default = True, 76 required = False, 77 ) 78 73 79 p_level = schema.Int( 74 80 title = _(u'Payment Level'), -
main/waeup.fceokene/trunk/src/waeup/fceokene/students/tests/test_browser.py
r9143 r9153 243 243 self.assertEqual(payment.p_item, u'') 244 244 self.assertEqual(error, None) 245 246 error, payment = utils.setPaymentDetails('schoolfee',self.student, 2004, 100) 247 self.assertEqual(error, u'Previous session payment not yet implemented.') 245 248 return -
main/waeup.fceokene/trunk/src/waeup/fceokene/students/utils.py
r9143 r9153 49 49 return new_session, new_level 50 50 51 def setPaymentDetails(self, category, student): 51 def setPaymentDetails(self, category, student, 52 previous_session=None, previous_level=None): 52 53 """Create Payment object and set the payment data of a student for 53 54 the payment category specified. … … 58 59 amount = 0.0 59 60 error = u'' 61 if previous_session: 62 return _('Previous session payment not yet implemented.'), None 60 63 p_session = student['studycourse'].current_session 61 64 p_level = student['studycourse'].current_level 65 p_current = True 62 66 session = str(p_session) 63 67 try: … … 207 211 payment.p_session = p_session 208 212 payment.p_level = p_level 213 payment.p_current = p_current 209 214 payment.amount_auth = float(amount) 210 215 return None, payment
Note: See TracChangeset for help on using the changeset viewer.