Changeset 3872 for WAeUP_SRP/trunk/skins/waeup_aaue
- Timestamp:
- 23 Jan 2009, 12:24:32 (16 years ago)
- Location:
- WAeUP_SRP/trunk/skins/waeup_aaue
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/skins/waeup_aaue/getSchoolFee.py
r3865 r3872 12 12 return SchoolFee 13 13 """ 14 14 MBL= ('MBA','MPAD','LLMCPL','LLMPIL') 15 15 16 16 d = {} 17 17 18 if brain.mode == '': 19 20 21 22 18 if brain.mode.endswith('_ft'): 19 # fresh full-time remedial 20 if str(brain.level) == '000' and brain.review_state == 'cleared_and_validated': 21 if brain.jamb_state == 'edo': 22 d['all'] = 50000 23 else: 24 d['all'] = 60000 25 # fresh tull-time students 26 elif str(brain.level) == '100' and brain.review_state == 'cleared_and_validated' and brain.faculty=='INE': 27 if brain.jamb_state == 'edo': 28 d['all'] = 22000 29 else: 30 d['all'] = 0 31 # returning full-time students 32 elif str(brain.level) == ('100','200','300','400') and brain.review_state == 'returning': 33 if brain.jamb_state == 'edo': 34 d['all'] = 4300 35 else: 36 d['all'] = 0 37 # postgrad full-time students 38 elif str(brain.level) == ('600') and brain.review_state == 'cleared_and_validated': 39 if brain.jamb_state == 'edo': 40 d['all'] = 62500 41 if brain.jamb_lga == 'foreigner': 42 d['all'] = 189500 43 else: 44 d['all'] = 69500 45 elif str(brain.level) == ('700','800') and brain.certificate in 'MBL': 46 if brain.jamb_state == 'edo': 47 d['all'] = 89500 48 if brain.jamb_lga == 'foreigner': 49 d['all'] = 269500 50 else: 51 d['all'] = 99500 52 elif str(brain.level) == ('700','800') and not in 'MBL': 53 if brain.jamb_state == 'edo': 54 d['all'] = 69500 55 if brain.jamb_lga == 'foreigner': 56 d['all'] = 219500 57 else: 58 d['all'] = 79500 59 elif str(brain.level) == ('900','1000','1001'): 60 if brain.jamb_state == 'edo': 61 d['all'] = 99500 62 if brain.jamb_lga == 'foreigner': 63 d['all'] = 269500 64 else: 65 d['all'] = 109500 66 else: 67 # fresh part-time students 68 elif str(brain.level) == '100' and brain.review_state == 'cleared_and_validated' and brain.faculty=='INE': 69 if brain.jamb_state == 'edo': 70 d['all'] = 45000 71 else: 72 d['all'] = 55000 73 # returning part-time students 74 elif str(brain.level) == ('100','200','300','400') and brain.review_state == 'returning': 75 if brain.jamb_state == 'edo': 76 d['all'] = 30000 77 else: 78 d['all'] = 40000 79 # postgrad part-time students 80 elif str(brain.level) == ('600') and brain.review_state == 'cleared_and_validated': 81 if brain.jamb_state == 'edo': 82 d['all'] = 64500 83 if brain.jamb_lga == 'foreigner': 84 d['all'] = 219500 85 else: 86 d['all'] = 74500 23 87 else: 24 88 d['all'] = 0 25 89 26 d['all'] = 027 90 28 91 next_info = context.getNextInfo(brain) … … 32 95 33 96 return d 97 -
WAeUP_SRP/trunk/skins/waeup_aaue/pay_interswitch.py
r3841 r3872 48 48 return context.interswitch_form(info=info) 49 49 50 info['site_id'] = '11 9'50 info['site_id'] = '115' 51 51 info['currency_id'] = '566' 52 pay_item_id = "1 0900"52 pay_item_id = "11900" 53 53 54 54 #info['type_code'] = sbrain.course #type_code is redundant and will be removed soon … … 67 67 now = DateTime.DateTime() 68 68 info['date'] = now 69 info['pay_ship_to'] = "A dekunle Ajasin University"69 info['pay_ship_to'] = "Ambrose Alli University Ekpoma" 70 70 timestamp = "%d" % int(now.timeTime()*1000) 71 71 info['order_id'] = "%s%s" % (student_id[1:],timestamp) 72 72 p_id = "p%s" % timestamp 73 74 75 info['surcharge'] = interswitch_amount = '150' 73 info['surcharge'] = interswitch_amount = 300 76 74 info['amount'] = amount = fee_dict['all'] 77 total_amount = 100*int(amount) + 100*int(interswitch_amount)78 79 75 80 76 if student_id is None: … … 82 78 83 79 if True: 84 info['action'] = "https://webpay.interswitchng.com/ test_paydirect/webpay/pay.aspx"80 info['action'] = "https://webpay.interswitchng.com/paydirect/webpay/pay.aspx" 85 81 else: 86 82 #pass … … 113 109 p_id, 114 110 p_id) 111 112 113 115 114 116 115 logger.info('%(student_id)s initiated online school fee payment with order_id %(order_id)s and callback url %(callback_url)s' % info) … … 129 128 130 129 bt_amount = 4000 130 aaue_split = 1000 131 131 132 aaue_amount = amount - bt_amount 132 #getSchoolFee provides pure school fee, the other fees have to be added 133 total_amount = 100* (amount + interswitch_amount + bt_amount + aaue_split) 134 135 133 136 xmldict = {} 134 137 xmldict['detail_ref'] = args['txn_ref'] 135 138 xmldict['department'] = student_record.department 136 139 xmldict['faculty'] = student_record.faculty 137 xmldict['a aue_amount'] = "%d" % int(100*aaue_amount)140 xmldict['amount'] = "%d" % int(100*amount) 138 141 xmldict['bt_amount'] = "%d" % int(100*bt_amount) 139 if student_record.mode.endswith('_pt'): 140 xmldict['aaue_acct'] = "" 141 elif student_record.mode.endswith('_sw'): 142 xmldict[' aaue_acct'] = ""142 143 if student_record.mode in ('ug_ft','ug_pt','pg_ft','pgd_ft): 144 xmldict['aaue_acct'] = "6020008887" 145 xmldict['bank_id'] = '123' 143 146 else: 144 xmldict['aaue_acct'] = "0000000000000000" 147 xmldict['aaue_acct'] = "0000000000000" 148 xmldict['bank_id'] = '0' 149 150 xmldict['aaue_split'] = "%d" % int(100*aaue_split) 145 151 146 152 147 153 xmltext = """<payment_item_detail> 148 <item_details detail_ref="%(detail_ref)s" college="AAUE" department="%(department)s" faculty="%(faculty)s"> 149 <item_detail item_id="1" item_name="AAUE" item_amt="%(aaue_amount)s" bank_id="89" acct_num="%(aaue_acct)s" /> 150 <item_detail item_id="2" item_name="BT" item_amt="%(bt_amount)s" bank_id="117" acct_num="6012015294" /> 154 <item_details detail_ref="%(detail_ref)s" college="aaue" department="%(department)s" faculty="%(faculty)s" > 155 <item_detail item_id="1" item_name="AAUE School Fee" item_amt="%(amount)s" bank_id="123" acct_num="6020008887" /> 156 <item_detail item_id="2" item_name="AAUE Split" item_amt="%(aaue_split)s" bank_id="123" acct_num="6020008887" /> 157 <item_detail item_id="3" item_name="BT" item_amt="%(bt_amount)s" bank_id="89" acct_num="0061001000021096" /> 151 158 </item_details> 152 159 </payment_item_detail>""" % xmldict … … 158 165 args['cust_name_desc'] = "Student Name" 159 166 args['pay_item_id'] = pay_item_id 160 args['pay_item_name'] = "A AUETuition Payments"167 args['pay_item_name'] = "Ambrose Alli University Ekpoma Tuition Payments" 161 168 args['payment_params'] = 'college_split' 162 169 #args['xml_data'] = ''
Note: See TracChangeset for help on using the changeset viewer.