Changeset 3739
- Timestamp:
- 28 Oct 2008, 14:57:23 (16 years ago)
- Location:
- WAeUP_SRP/trunk/skins/waeup_fceoyo
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/skins/waeup_fceoyo/getSchoolFee.py
r3714 r3739 14 14 15 15 16 ARTS = ('CRS','ISS',' HIS','MUS','ECO','GEO','POL','SOS','CCA','ECU','THA','GED','GSE','PES','SPC','ENG ','FRE','ARB','HAU','IGB','YOR','FAA')16 ARTS = ('CRS','ISS','MUS','SOS','THA','PES') 17 17 18 # SCS = ('BIO',' CHE','HED','MAT','PED','PHY ','CSC','ISC','PHE','AGE','BED','HEC','TED')18 # SCS = ('BIO','HEC','MAT','ARB','ISC','IGB','YOR','HAU','ENG ','FRE','PHY ','CSC','PHE','AGE','FAA','BED','HEC') 19 19 20 20 d = {} … … 23 23 if str(brain.level) == '000' and brain.review_state == 'cleared_and_validated': 24 24 if brain.department in ARTS: 25 d['all'] = 1 590025 d['all'] = 16950 26 26 else: 27 d['all'] = 1 640027 d['all'] = 17550 28 28 elif str(brain.level) == '100' and brain.review_state == 'cleared_and_validated': 29 29 if brain.department in ARTS: 30 d['all'] = 1302030 d['all'] = 9820 31 31 else: 32 d['all'] = 1 349532 d['all'] = 10420 33 33 elif str(brain.level) == '100' and brain.review_state == 'returning': 34 34 if brain.department in ARTS: 35 d['all'] = 1207035 d['all'] = 7820 36 36 else: 37 d['all'] = 1254537 d['all'] = 8420 38 38 elif str(brain.level) in ('200','210','220'): 39 39 if brain.department in ARTS: 40 d['all'] = 1207040 d['all'] = 5450 41 41 else: 42 d['all'] = 1254542 d['all'] = 6050 43 43 # repeaters = spillover 44 elif str(brain.level) in ('300','310','320'):44 elif str(brain.level) == '300': 45 45 if brain.department in ARTS: 46 d['all'] = 1017046 d['all'] = 6200 47 47 else: 48 d['all'] = 10645 48 d['all'] = 6800 49 elif str(brain.level) in ('310','320'): 50 if brain.department in ARTS: 51 d['all'] = 4950 52 else: 53 d['all'] = 6800 49 54 else: 50 55 d['all'] = 0 … … 52 57 if str(brain.level) == '100' and brain.review_state == 'cleared_and_validated': 53 58 if brain.department in ARTS: 54 d['all'] = 2190059 d['all'] = 11000 55 60 else: 56 d['all'] = 2240061 d['all'] = 11000 57 62 elif str(brain.level) == '100' and brain.review_state == 'returning': 58 63 if brain.department in ARTS: 59 d['all'] = 1 840064 d['all'] = 11000 60 65 else: 61 d['all'] = 1 890066 d['all'] = 11000 62 67 elif str(brain.level) in ('200','210','220'): 63 68 if brain.department in ARTS: 64 d['all'] = 2040069 d['all'] = 10000 65 70 else: 66 d['all'] = 2090071 d['all'] = 10000 67 72 elif str(brain.level) in ('300','310','320'): 68 73 if brain.department in ARTS: 69 d['all'] = 1840074 d['all'] = 9500 70 75 else: 71 d['all'] = 1890076 d['all'] = 9500 72 77 78 # repeaters = spillover 73 79 elif str(brain.level) in ('400','410','420'): 74 80 if brain.department in ARTS: 75 d['all'] = 1840081 d['all'] = 9000 76 82 else: 77 d['all'] = 1890083 d['all'] = 9000 78 84 79 # repeaters = spillover80 elif str(brain.level) in ('500','510','520'):81 if brain.department in ARTS:82 d['all'] = 1690083 else:84 d['all'] = 1740085 85 else: 86 86 d['all'] = 0 -
WAeUP_SRP/trunk/skins/waeup_fceoyo/pay_interswitch.py
r3714 r3739 48 48 return context.interswitch_form(info=info) 49 49 50 info['site_id'] = ' 83'50 info['site_id'] = '115' 51 51 info['currency_id'] = '566' 52 pay_item_id = "11500" 52 53 53 pay_item_id = "8302"54 54 #info['type_code'] = sbrain.course #type_code is redundant and will be removed soon 55 55 info['bank'] = '' … … 67 67 now = DateTime.DateTime() 68 68 info['date'] = now 69 info['pay_ship_to'] = "Federal College of Education O kene"69 info['pay_ship_to'] = "Federal College of Education Oyo" 70 70 timestamp = "%d" % int(now.timeTime()*1000) 71 71 info['order_id'] = "%s%s" % (student_id[1:],timestamp) … … 73 73 74 74 75 info['surcharge'] = interswitch_amount = ' 150'75 info['surcharge'] = interswitch_amount = '300' 76 76 info['amount'] = amount = fee_dict['all'] 77 77 total_amount = 100*int(amount) + 100*int(interswitch_amount) … … 82 82 83 83 if True: 84 info['action'] = "https://webpay.interswitchng.com/ paydirect/webpay/pay.aspx"84 info['action'] = "https://webpay.interswitchng.com/test_paydirect/webpay/pay.aspx" 85 85 else: 86 86 #pass … … 128 128 args[arg] = info[field] 129 129 130 bt_amount = 1750 131 132 fceoyo_amount = amount - bt_amount # das ist falsch hier 133 134 xmldict = {} 135 xmldict['detail_ref'] = args['txn_ref'] 136 xmldict['department'] = student_record.department 137 xmldict['faculty'] = student_record.faculty 138 xmldict['fceoyo_amount'] = "%d" % int(100*fceoyo_amount) 139 xmldict['bt_amount'] = "%d" % int(100*bt_amount) 140 141 if student_record.mode.endswith('_pt'): 142 xmldict['fceoyo_acct'] = "0321100000000046" 143 elif student_record.mode.endswith('_sw'): 144 xmldict['fceoyo_acct'] = "0321100000000056" 145 else: 146 xmldict['fceoyo_acct'] = "0000000000000000" 147 148 149 xmltext = """<payment_item_detail> 150 <item_details detail_ref="%(detail_ref)s" college="fceoyo" department="%(department)s" faculty="%(faculty)s"> 151 <item_detail item_id="1" item_name="fceoyo" item_amt="%(fceoyo_amount)s" bank_id="89" acct_num="%(fceoyo_acct)s" /> 152 <item_detail item_id="2" item_name="BT" item_amt="%(bt_amount)s" bank_id="89" acct_num="0061001000021095" /> 153 </item_details> 154 </payment_item_detail>""" % xmldict 155 156 info['xml_data'] = """<input type="hidden" name="xml_data" value='%s' />""" % xmltext 157 130 158 args['Amount'] = "%d" % (total_amount) 131 args['site_name'] = "fceo kene.waeup.org"159 args['site_name'] = "fceoyo.waeup.org" 132 160 args['cust_name_desc'] = "Student Name" 133 161 args['pay_item_id'] = pay_item_id 134 args['pay_item_name'] = "FCEOKENE Tuition Payments" 135 args['payment_params'] = 'switch_college_split' 136 args['xml_data'] = '' 162 args['pay_item_name'] = "FCE Oyo Tuition Payments" 163 args['payment_params'] = 'college_split' 164 #args['xml_data'] = '' 165 #args['xml_data'] = xmltext # info['xml_data']can be used instead 137 166 info['args'] = args 167 138 168 return context.goto_interswitch_form(info=info) 169
Note: See TracChangeset for help on using the changeset viewer.