Changeset 14616 for main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students
- Timestamp:
- 9 Mar 2017, 10:42:42 (8 years ago)
- Location:
- main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/utils.py
r14587 r14616 28 28 from waeup.kofa.fees import FeeTable 29 29 from waeup.kofa.hostels.hostel import NOT_OCCUPIED 30 from waeup.kwarapoly.interswitch.browser import GATEWAY_AMT 30 31 from waeup.kwarapoly.interfaces import MessageFactory as _ 31 32 … … 277 278 return None, payment 278 279 280 def setBalanceDetails(self, category, student, 281 balance_session, balance_level, balance_amount): 282 """Create a balance payment ticket and set the payment data 283 as selected by the student. Kwarapoly: Add Interswitch surcharge 284 """ 285 p_item = u'Balance' 286 p_session = balance_session 287 p_level = balance_level 288 p_current = False 289 amount = balance_amount 290 academic_session = self._getSessionConfiguration(p_session) 291 if academic_session == None: 292 return _(u'Session configuration object is not available.'), None 293 if amount in (0.0, None) or amount < 0: 294 return _('Amount must be greater than 0.'), None 295 payment = createObject(u'waeup.StudentOnlinePayment') 296 timestamp = ("%d" % int(time()*10000))[1:] 297 payment.p_id = "p%s" % timestamp 298 payment.p_category = category 299 payment.p_item = p_item 300 payment.p_session = p_session 301 payment.p_level = p_level 302 payment.p_current = p_current 303 payment.amount_auth = amount + GATEWAY_AMT 304 return None, payment 305 279 306 def getAccommodationDetails(self, student): 280 307 """Determine the accommodation data of a student. -
main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/viewlets.py
r12907 r14616 35 35 return '' 36 36 37 class AddBalancePaymentActionButton(AddBalancePaymentActionButton):37 #class AddBalancePaymentActionButton(AddBalancePaymentActionButton): 38 38 39 @property40 def target_url(self):41 return ''39 # @property 40 # def target_url(self): 41 # return '' 42 42 43 43 class AdmissionNotificationActionButton(ManageActionButton):
Note: See TracChangeset for help on using the changeset viewer.