Index: main/waeup.aaue/trunk/src/waeup/aaue/students/acceptancefees.csv
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/acceptancefees.csv	(revision 17431)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/acceptancefees.csv	(revision 17431)
@@ -0,0 +1,95 @@
+code,faculty_code,department_code,session,acceptance,matricgown,lapel
+CERT1,FAG,ANS,#2022,14000,2000,800
+BAGRANS,FAG,ANS,#2022,62400,2000,800
+BAGRCRS,FAG,CRS,#2022,62400,2000,800
+BAGREES,FAG,EES,#2022,62400,2000,800
+BAGRSOS,FAG,SOS,#2022,62400,2000,800
+BAENG,FAT,ENG,#2022,62400,2000,800
+BAFRN,FAT,FRN,#2022,62400,2000,800
+BAHIS,FAT,HIS,#2022,62400,2000,800
+BAISD,FAT,HIS,#2022,62400,2000,800
+BAMAC,FAT,MAC,#2022,62400,2000,800
+BAPHI,FAT,PHI,#2022,62400,2000,800
+BARCS,FAT,RCS,#2022,62400,2000,800
+BARST,FAT,RCS,#2022,62400,2000,800
+BATMA,FAT,TMA,#2022,62400,2000,800
+BSCANA,FBM,ANA,#2022,62400,2000,800
+BMLS,FBM,MLS,#2022,67400,2000,800
+BMLSCHMP,FBM,MLS,#2022,67400,2000,800
+BMLSHBTS,FBM,MLS,#2022,67400,2000,800
+BMLSHIST,FBM,MLS,#2022,67400,2000,800
+BMLSMMCB,FBM,MLS,#2022,67400,2000,800
+BSCNSG,FBM,NSG,#2022,67400,2000,800
+BSCPHS,FBM,PHS,#2022,62400,2000,800
+BSCPYS,FBM,PYS,#2022,62400,2000,800
+MBBS,FCS,MED,#2022,77400,2000,800
+BEDACC,FED,BED,#2022,62400,2000,800
+BEDOTM,FED,BED,#2022,62400,2000,800
+BEDSEC,FED,BED,#2022,62400,2000,800
+BEDBIO,FED,CAI,#2022,62400,2000,800
+BEDCHM,FED,CAI,#2022,62400,2000,800
+BEDCSC,FED,CAI,#2022,62400,2000,800
+BEDENG,FED,CAI,#2022,62400,2000,800
+BEDFRN,FED,CAI,#2022,62400,2000,800
+BEDMTH,FED,CAI,#2022,62400,2000,800
+BEDPHY,FED,CAI,#2022,62400,2000,800
+BEDPPE,FED,CAI,#2022,62400,2000,800
+BEDSSE,FED,CAI,#2022,62400,2000,800
+CAI,FED,CAI,#2022,62400,2000,800
+BEDEDM,FED,EFM,#2022,62400,2000,800
+BEDHIS,FED,EFM,#2022,62400,2000,800
+BEDRSE,FED,EFM,#2022,62400,2000,800
+EFM,FED,EFM,#2022,62400,2000,800
+BEDECO,FED,GAC,#2022,62400,2000,800
+BEDGAC,FED,GAC,#2022,62400,2000,800
+BEDGEO,FED,GAC,#2022,62400,2000,800
+BEDPOL,FED,GAC,#2022,62400,2000,800
+BEDHED,FED,HKH,#2022,62400,2000,800
+BEDHKE,FED,HKH,#2022,62400,2000,800
+BEDPHE,FED,HKH,#2022,62400,2000,800
+BSCLIS,FED,LIS,#2022,62400,2000,800
+BEDAGR,FED,VTE,#2022,62400,2000,800
+BEDHECO,FED,VTE,#2022,62400,2000,800
+BEDTEC,FED,VTE,#2022,62400,2000,800
+VTE,FED,VTE,#2022,62400,2000,800
+BSCARC,FES,ARC,#2022,62400,2000,800
+BSCBLD,FES,BLD,#2022,62400,2000,800
+BFA,FES,FAA,#2022,62400,2000,800
+BFAGRH,FES,FAA,#2022,62400,2000,800
+BFAPNT,FES,FAA,#2022,62400,2000,800
+BFASC,FES,FAA,#2022,62400,2000,800
+BFATD,FES,FAA,#2022,62400,2000,800
+BSCFAA,FES,FAA,#2022,62400,2000,800
+BSCGEM,FES,GEM,#2022,62400,2000,800
+BSCGRP,FES,GEM,#2022,62400,2000,800
+BENGAGE,FET,AGE,#2022,62400,2000,800
+BENGCIE,FET,CIE,#2022,62400,2000,800
+BENGELE,FET,ELE,#2022,62400,2000,800
+BENGIPE,FET,IPE,#2022,62400,2000,800
+BENGMPE,FET,IPE,#2022,62400,2000,800
+BENGPE,FET,IPE,#2022,62400,2000,800
+BENGMEE,FET,MEE,#2022,62400,2000,800
+BENGMME,FET,MME,#2022,62400,2000,800
+BSCBCH,FLS,BCH,#2022,62400,2000,800
+BSCBOT,FLS,BOT,#2022,62400,2000,800
+BSCHND,FLS,HND,#2022,62400,2000,800
+BSCMCB,FLS,MCB,#2022,62400,2000,800
+BSCPSB,FLS,PSB,#2022,62400,2000,800
+BSCZOO,FLS,ZOO,#2022,62400,2000,800
+LLB,FLW,LAW,#2022,67400,2000,800
+BSCACC,FMS,ACC,#2022,62400,2000,800
+BSCBAF,FMS,BAF,#2022,62400,2000,800
+BSCBUS,FMS,BUS,#2022,62400,2000,800
+BSCPUB,FMS,PUB,#2022,62400,2000,800
+BSCCHM,FPS,CHM,#2022,62400,2000,800
+BSCICH,FPS,CHM,#2022,62400,2000,800
+BSCCSC,FPS,CSC,#2022,62400,2000,800
+BSCIMTH,FPS,MTH,#2022,62400,2000,800
+BSCMTH,FPS,MTH,#2022,62400,2000,800
+BSCSTA,FPS,MTH,#2022,62400,2000,800
+BSCAPHY,FPS,PHY,#2022,62400,2000,800
+BSCPHY,FPS,PHY,#2022,62400,2000,800
+BSCECO,FSS,ECO,#2022,62400,2000,800
+BSCPOL,FSS,POL,#2022,62400,2000,800
+BSCPSY,FSS,PSY,#2022,62400,2000,800
+BSCSOC,FSS,SOC,#2022,62400,2000,800
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py	(revision 17430)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py	(revision 17431)
@@ -90,5 +90,4 @@
     ICustomStudentBase,
     ICustomStudentStudyCourse)
-from waeup.aaue.interswitch.browser import gateway_net_amt
 from waeup.aaue.interfaces import MessageFactory as _
 
@@ -340,6 +339,4 @@
         if self.context.p_category in ('schoolfee_incl', 'schoolfee_1') \
             and academic_session:
-            #welfare_fee = gateway_net_amt(academic_session.welfare_fee)
-            #union_fee = gateway_net_amt(academic_session.union_fee)
             if self.context.student.entry_session == 2016 \
                 and self.context.student.entry_mode == 'ug_ft' \
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/schoolfees.csv
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/schoolfees.csv	(revision 17431)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/schoolfees.csv	(revision 17431)
@@ -0,0 +1,95 @@
+code,faculty_code,department_code,session,tuition,edohis,union,access,notebook,sport,library,lmsplus,nuga
+CERT1,FAG,ANS,#2022,184000,16000,1000,4500,9000,3000,1000,20000,1000
+BAGRANS,FAG,ANS,#2022,184000,16000,1000,4500,9000,3000,1000,20000,1000
+BAGRCRS,FAG,CRS,#2022,184000,16000,1000,4500,9000,3000,1000,20000,1000
+BAGREES,FAG,EES,#2022,184000,16000,1000,4500,9000,3000,1000,20000,1000
+BAGRSOS,FAG,SOS,#2022,184000,16000,1000,4500,9000,3000,1000,20000,1000
+BAENG,FAT,ENG,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BAFRN,FAT,FRN,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BAHIS,FAT,HIS,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BAISD,FAT,HIS,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BAMAC,FAT,MAC,#2022,248250,16000,1000,4500,9000,3000,1000,20000,1000
+BAPHI,FAT,PHI,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BARCS,FAT,RCS,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BARST,FAT,RCS,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BATMA,FAT,TMA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCANA,FBM,ANA,#2022,281000,16000,1000,4500,9000,3000,1000,20000,1000
+BMLS,FBM,MLS,#2022,554500,16000,1000,4500,9000,3000,1000,20000,1000
+BMLSCHMP,FBM,MLS,#2022,554500,16000,1000,4500,9000,3000,1000,20000,1000
+BMLSHBTS,FBM,MLS,#2022,554500,16000,1000,4500,9000,3000,1000,20000,1000
+BMLSHIST,FBM,MLS,#2022,554500,16000,1000,4500,9000,3000,1000,20000,1000
+BMLSMMCB,FBM,MLS,#2022,554500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCNSG,FBM,NSG,#2022,666000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPHS,FBM,PHS,#2022,204000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPYS,FBM,PYS,#2022,204000,16000,1000,4500,9000,3000,1000,20000,1000
+MBBS,FCS,MED,#2022,786000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDACC,FED,BED,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDOTM,FED,BED,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDSEC,FED,BED,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDBIO,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDCHM,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDCSC,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDENG,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDFRN,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDMTH,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDPHY,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDPPE,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDSSE,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+CAI,FED,CAI,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDEDM,FED,EFM,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDHIS,FED,EFM,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDRSE,FED,EFM,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+EFM,FED,EFM,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDECO,FED,GAC,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDGAC,FED,GAC,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDGEO,FED,GAC,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDPOL,FED,GAC,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDHED,FED,HKH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDHKE,FED,HKH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDPHE,FED,HKH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCLIS,FED,LIS,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BEDAGR,FED,VTE,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDHECO,FED,VTE,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BEDTEC,FED,VTE,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+VTE,FED,VTE,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCARC,FES,ARC,#2022,224500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCBLD,FES,BLD,#2022,224500,16000,1000,4500,9000,3000,1000,20000,1000
+BFA,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BFAGRH,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BFAPNT,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BFASC,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BFATD,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCFAA,FES,FAA,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCGEM,FES,GEM,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCGRP,FES,GEM,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BENGAGE,FET,AGE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGCIE,FET,CIE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGELE,FET,ELE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGIPE,FET,IPE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGMPE,FET,IPE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGPE,FET,IPE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGMEE,FET,MEE,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BENGMME,FET,MME,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCBCH,FLS,BCH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCBOT,FLS,BOT,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCHND,FLS,HND,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCMCB,FLS,MCB,#2022,224000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPSB,FLS,PSB,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCZOO,FLS,ZOO,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+LLB,FLW,LAW,#2022,657500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCACC,FMS,ACC,#2022,312500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCBAF,FMS,BAF,#2022,202500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCBUS,FMS,BUS,#2022,282500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPUB,FMS,PUB,#2022,282500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCCHM,FPS,CHM,#2022,264000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCICH,FPS,CHM,#2022,264000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCCSC,FPS,CSC,#2022,274500,16000,1000,4500,9000,3000,1000,20000,1000
+BSCIMTH,FPS,MTH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCMTH,FPS,MTH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCSTA,FPS,MTH,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCAPHY,FPS,PHY,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPHY,FPS,PHY,#2022,214000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCECO,FSS,ECO,#2022,232000,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPOL,FSS,POL,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCPSY,FSS,PSY,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
+BSCSOC,FSS,SOC,#2022,198250,16000,1000,4500,9000,3000,1000,20000,1000
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py	(revision 17430)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py	(revision 17431)
@@ -179,5 +179,5 @@
         cpt_value = ctrl.options[0]
         # School fee payment ticket can be added ...
-        self.student['studycourse'].certificate.school_fee_3 = 6666.0
+        #self.student['studycourse'].certificate.school_fee_3 = 6666.0
         self.student.nationality = u'NG'
         self.browser.open(self.payments_path + '/addop')
@@ -222,8 +222,8 @@
                            self.browser.contents)
         self.browser.open(self.payments_path + '/addop')
-        self.browser.getControl(name="form.p_category").value = ['late_registration']
-        self.browser.getControl("Create ticket").click()
-        self.assertMatches('...ticket created...',
-                           self.browser.contents)
+        #self.browser.getControl(name="form.p_category").value = ['late_registration']
+        #self.browser.getControl("Create ticket").click()
+        #self.assertMatches('...ticket created...',
+        #                   self.browser.contents)
         return
 
@@ -233,7 +233,7 @@
         self.app['configuration'].addSessionConfiguration(configuration_1)
         self.student['studycourse'].certificate.study_mode = 'ug_pt'
-        self.student['studycourse'].certificate.school_fee_2 = 6666.0
-        self.app['configuration']['2015'].union_fee = 1250.0
-        self.app['configuration']['2015'].welfare_fee = 750.0
+        #self.student['studycourse'].certificate.school_fee_2 = 6666.0
+        #self.app['configuration']['2015'].union_fee = 1250.0
+        #self.app['configuration']['2015'].welfare_fee = 750.0
         self.student.nationality = u'NG'
         self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')
@@ -282,8 +282,6 @@
         self.assertEqual(self.student['payments'].values()[0].p_category, 'schoolfee_1')
         self.assertEqual(self.student['payments'].values()[1].p_category, 'schoolfee_2')
-        # (6666-200)/2 + 1250 + 750 - 400 + 200
-        self.assertEqual(self.student['payments'].values()[0].amount_auth, 5033.0)
-        # (6666-200)/2 + 200
-        self.assertEqual(self.student['payments'].values()[1].amount_auth, 3433.0)
+        self.assertEqual(self.student['payments'].values()[0].amount_auth, 147500.0)
+        self.assertEqual(self.student['payments'].values()[1].amount_auth, 92000.0)
         # The  two payments belong to the same session and level.
         self.assertEqual(self.student['payments'].values()[0].p_session, 2015)
@@ -296,7 +294,7 @@
         configuration_2.academic_session = 2016
         self.app['configuration'].addSessionConfiguration(configuration_2)
-        self.student['studycourse'].certificate.school_fee_2 = 5666.0
-        self.app['configuration']['2016'].union_fee = 1250.0
-        self.app['configuration']['2016'].welfare_fee = 750.0
+        #self.student['studycourse'].certificate.school_fee_2 = 5666.0
+        #self.app['configuration']['2016'].union_fee = 1250.0
+        #self.app['configuration']['2016'].welfare_fee = 750.0
         self.student.father_name = u'Albert'
         IWorkflowState(self.student).setState('returning')
@@ -317,8 +315,6 @@
         self.browser.getControl("Create ticket").click()
         self.assertTrue('ticket created' in self.browser.contents)
-        # (5666-200)/2 + 1250 + 750 - 400 + 200
-        self.assertEqual(self.student['payments'].values()[2].amount_auth, 4533.0)
-        # (5666-200)/2 + 200
-        self.assertEqual(self.student['payments'].values()[3].amount_auth, 2933.0)
+        self.assertEqual(self.student['payments'].values()[2].amount_auth, 147500.0)
+        self.assertEqual(self.student['payments'].values()[3].amount_auth, 92000.0)
         # The last two payments belong to the same session and level.
         self.assertEqual(self.student['payments'].values()[2].p_session, 2016)
@@ -329,5 +325,5 @@
 
     def test_manage_payments_bypass_ac_creation(self):
-        self.student['studycourse'].certificate.school_fee_3 = 6666.0
+        #self.student['studycourse'].certificate.school_fee_3 = 6666.0
         self.student.nationality = u'NG'
         self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')
@@ -365,5 +361,5 @@
         logcontent = open(logfile).read()
         self.assertTrue(
-            '"zope.mgr",E1000000,%s,schoolfee_incl,6666.0,AP,,,,,,\n' % value
+            '"zope.mgr",E1000000,%s,schoolfee_incl,239500.0,AP,,,,,,\n' % value
             in logcontent)
         # Student is in state school fee paid, no activation
@@ -563,5 +559,5 @@
 
     def test_payment_disabled(self):
-        self.student['studycourse'].certificate.school_fee_3 = 6666.0
+        #self.student['studycourse'].certificate.school_fee_3 = 6666.0
         self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')
         self.browser.open(self.payments_path)
@@ -621,5 +617,5 @@
         self.student['accommodation'].addBedTicket(bedticket)
 
-    def test_maintenance_fee_payment(self):
+    def deactivated_test_maintenance_fee_payment(self):
         self.certificate.study_mode = 'ug_ft'
         self.student['studycourse'].entry_session = 2013
@@ -649,5 +645,5 @@
         self.student['studycourse'].current_session = 2018
         self.student['studycourse'].entry_mode = 'ug_ft'
-        self.student['studycourse'].certificate.school_fee_2 = 50200.0
+        #self.student['studycourse'].certificate.school_fee_2 = 50200.0
         self.app['configuration']['2018'].union_fee = 1200.0
         self.app['configuration']['2018'].welfare_fee = 700.0
@@ -672,6 +668,5 @@
         self.browser.getLink(value).click()
         self.assertTrue('Amount Authorized' in self.browser.contents)
-        # 50200 + 1200 + 700 + 300 + 300- 800 = 51900
-        self.assertEqual(self.student['payments'][value].amount_auth, 51900.0)
+        self.assertEqual(self.student['payments'][value].amount_auth, 239500.0)
         self.student['payments'][value].r_company = u'interswitch'
         self.browser.getLink("Download").click()
@@ -692,5 +687,5 @@
         return
 
-    def test_late_registration(self):
+    def deactivated_test_late_registration(self):
         delta = timedelta(days=10)
         self.app['configuration'][
@@ -982,5 +977,5 @@
             in self.browser.contents)
         # 2nd instalment has to be paid first
-        self.certificate.school_fee_3 = 678.0
+        #self.certificate.school_fee_3 = 678.0
         self.browser.open(self.payments_path + '/addop')
         self.browser.getControl(name="form.p_category").value = ['schoolfee_2']
@@ -993,5 +988,5 @@
         return
 
-    def test_student_GST_registration(self):
+    def deactivated_test_student_GST_registration(self):
         configuration_1 = createObject('waeup.SessionConfiguration')
         configuration_1.academic_session = 2016
@@ -1087,5 +1082,5 @@
         return
 
-    def test_course_registration_forbidden_2(self):
+    def deactivated_test_course_registration_forbidden_2(self):
         IWorkflowState(self.student).setState('school fee paid')
         self.student['studycourse'].entry_session = 2004
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py	(revision 17430)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py	(revision 17431)
@@ -52,9 +52,9 @@
         self.app['configuration']['2004'].booking_fee = 150.0
         self.app['configuration']['2004'].maint_fee = 180.0
-        self.app['configuration']['2004'].clearance_fee_pg = 1234.0
-        self.app['configuration']['2004'].clearance_fee_fp = 3456.0
-        self.student['studycourse'].certificate.school_fee_1 = 6666.0
-        self.student['studycourse'].certificate.school_fee_2 = 7777.0
-        self.student['studycourse'].certificate.school_fee_3 = 8888.0
+        #self.app['configuration']['2004'].clearance_fee_pg = 1234.0
+        #self.app['configuration']['2004'].clearance_fee_fp = 3456.0
+        #self.student['studycourse'].certificate.school_fee_1 = 6666.0
+        #self.student['studycourse'].certificate.school_fee_2 = 7777.0
+        #self.student['studycourse'].certificate.school_fee_3 = 8888.0
         self.student['studycourse'].certificate.study_mode = 'special_pg_ft'
         self.student.nationality = u'NG'
@@ -74,5 +74,5 @@
         self.assertEqual(payment.p_level, 100)
         self.assertEqual(payment.p_session, 2004)
-        self.assertEqual(payment.amount_auth, 28888.0)
+        self.assertEqual(payment.amount_auth, 204000.0) # tuition plus penalty
         self.assertEqual(payment.p_item, u'CERT1')
         self.assertEqual(error, None)
@@ -84,5 +84,5 @@
         self.student.lga = 'edo_afuze'
         error, payment = utils.setPaymentDetails('schoolfee',self.student)
-        self.assertEqual(payment.amount_auth, 8987.0)
+        self.assertEqual(payment.amount_auth, 184099.0)
         IWorkflowState(self.student).setState('returning')
         error, payment = utils.setPaymentDetails('schoolfee',self.student)
@@ -94,30 +94,5 @@
         self.assertEqual(payment.p_level, 200)
         self.assertEqual(payment.p_session, 2005)
-        self.assertEqual(payment.amount_auth, 8976.0)
-        self.assertEqual(payment.p_item, u'CERT1')
-        self.assertEqual(error, None)
-
-        configuration = createObject('waeup.SessionConfiguration')
-        configuration.academic_session = 2016
-        self.app['configuration'].addSessionConfiguration(configuration)
-        configuration = createObject('waeup.SessionConfiguration')
-        configuration.academic_session = 2017
-        self.app['configuration'].addSessionConfiguration(configuration)
-        configuration = createObject('waeup.SessionConfiguration')
-        configuration.academic_session = 2018
-        self.app['configuration'].addSessionConfiguration(configuration)
-        self.student['studycourse'].current_session = 2017
-        self.student['studycourse'].entry_session = 2015
-        error, payment = utils.setPaymentDetails('schoolfee',self.student)
-        self.assertEqual(payment.p_level, 200)
-        self.assertEqual(payment.p_session, 2018)
-        self.assertEqual(payment.amount_auth, 7777.0)
-        self.assertEqual(payment.p_item, u'CERT1')
-        self.assertEqual(error, None)
-        self.student['studycourse'].entry_session = 2014
-        error, payment = utils.setPaymentDetails('schoolfee',self.student)
-        self.assertEqual(payment.p_level, 200)
-        self.assertEqual(payment.p_session, 2018)
-        self.assertEqual(payment.amount_auth, 8888.0)
+        self.assertEqual(payment.amount_auth, 184088.0)
         self.assertEqual(payment.p_item, u'CERT1')
         self.assertEqual(error, None)
@@ -133,27 +108,6 @@
         self.assertEqual(payment.p_level, 100)
         self.assertEqual(payment.p_session, 2004)
-        self.assertEqual(payment.amount_auth, 1234.0)
-        self.assertEqual(payment.p_item, u'CERT1')
-        self.assertEqual(error, None)
-
-        self.app['faculties']['fac1'].code = u'FP'
-        error, payment = utils.setPaymentDetails('clearance',self.student)
-        self.assertEqual(payment.p_level, 100)
-        self.assertEqual(payment.p_session, 2004)
-        self.assertEqual(payment.amount_auth, 3456.0)
-        self.assertEqual(payment.p_item, u'CERT1')
-        self.assertEqual(error, None)
-
-        error, payment = utils.setPaymentDetails('restitution',self.student)
-        self.assertEqual(error, 'Restitution fee payment not required.')
-        self.student['studycourse'].certificate.study_mode = 'ug_ft'
-        configuration = createObject('waeup.SessionConfiguration')
-        self.app['configuration']['2016'].restitution_fee = 1111.0
-        self.student['studycourse'].current_session = 2016
-        error, payment = utils.setPaymentDetails('restitution',self.student)
-        self.assertEqual(payment.p_level, 100)
-        self.assertEqual(payment.p_session, 2016)
-        self.assertEqual(payment.amount_auth, 1111.0)
-        self.assertEqual(payment.p_item, u'')
+        self.assertEqual(payment.amount_auth, 14000.0)
+        self.assertEqual(payment.p_item, u'CERT1')
         self.assertEqual(error, None)
 
@@ -164,5 +118,5 @@
         self.assertEqual(payment.p_level, 100)
         self.assertEqual(payment.p_session, 2004)
-        self.assertEqual(payment.amount_auth, 8888.0)
+        self.assertEqual(payment.amount_auth, 184099.0)
         self.assertEqual(payment.p_item, u'CERT1')
         self.assertEqual(error, None)
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py	(revision 17430)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py	(revision 17431)
@@ -17,4 +17,6 @@
 ##
 import grok
+import os
+import csv
 from time import time
 from zope.component import createObject, queryUtility
@@ -26,8 +28,16 @@
 from waeup.kofa.accesscodes import create_accesscode
 from waeup.kofa.students.utils import trans
-from waeup.aaue.interswitch.browser import gateway_net_amt, GATEWAY_AMT
 from waeup.aaue.interfaces import MessageFactory as _
 
 MINIMUM_UNITS_THRESHOLD = 15
+
+schoolfees_path = os.path.join(
+    os.path.dirname(__file__), 'schoolfees.csv')
+reader = csv.DictReader(open(schoolfees_path, 'rb'))
+SCHOOLFEES = {item['code']:(item['tuition'], item.values()) for item in reader}
+acceptancefees_path = os.path.join(
+    os.path.dirname(__file__), 'acceptancefees.csv')
+reader = csv.DictReader(open(acceptancefees_path, 'rb'))
+ACCEPTANCEFEES = {item['code']:(item['acceptance'], item.values()) for item in reader}
 
 class CustomStudentsUtils(NigeriaStudentsUtils):
@@ -312,10 +322,4 @@
             p_item = acco_details['bt']
             amount = academic_session.booking_fee
-        elif category == 'restitution':
-            if student.current_session != 2016 \
-                or student.current_mode not in ('ug_ft', 'dp_ft') \
-                or student.is_fresh:
-                return _(u'Restitution fee payment not required.'), None
-            amount = academic_session.restitution_fee
         elif category == 'hostel_maintenance':
             amount = 0.0
@@ -338,4 +342,9 @@
             if student.state not in (ADMITTED, CLEARANCE, REQUESTED, CLEARED):
                 return _(u'Acceptance Fee payments not allowed.'), None
+            try:
+                certificate = student['studycourse'].certificate
+                p_item = certificate.code
+            except (AttributeError, TypeError):
+                return _('Study course data are incomplete.'), None
             if student.current_mode in (
                 'ug_ft', 'ug_pt', 'de_ft', 'de_pt',
@@ -343,33 +352,19 @@
                 and category != 'clearance_incl':
                     return _("Additional fees must be included."), None
-            if student.current_mode == 'ijmbe':
-                amount = academic_session.clearance_fee_ijmbe
-            elif student.current_mode == 'bridge':
-                amount = academic_session.clearance_fee_bridge
-            elif student.current_mode == 'dp_ft':
-                amount = academic_session.clearance_fee_dp
-            elif student.faccode == 'FP':
-                amount = academic_session.clearance_fee_fp
-            elif student.current_mode in ('ug_pt', 'de_pt', 'ug_dsh', 'de_dsh'):
-                amount = academic_session.clearance_fee_ug_pt
-            elif student.current_mode == 'special_pg_pt':
-                amount = academic_session.clearance_fee_pg_pt
-            elif student.faccode == 'FCS':
-                # Students in clinical medical sciences pay the medical
-                # acceptance fee
-                amount = academic_session.clearance_fee_med
             elif student.current_mode == 'special_pg_ft':
                 if category != 'clearance':
                     return _("No additional fees required."), None
-                amount = academic_session.clearance_fee_pg
-            else:
-                amount = academic_session.clearance_fee
-            p_item = student['studycourse'].certificate.code
-            if amount in (0.0, None):
-                return _(u'Amount could not be determined.'), None
-            # Add Matric Gown Fee and Lapel Fee
+            try:
+                acceptancefees_entry = ACCEPTANCEFEES[student.certcode]
+            except KeyError:
+                return _('Acceptance fees not yet fixed.'), None
             if category == 'clearance_incl':
-                amount += gateway_net_amt(academic_session.matric_gown_fee) + \
-                    gateway_net_amt(academic_session.lapel_fee)
+                for item in acceptancefees_entry[1]:
+                    try:
+                        amount += int(item)
+                    except:
+                        pass
+            else:
+                amount = float(acceptancefees_entry[0])
         elif category == 'late_registration':
             if student.is_postgrad:
@@ -388,4 +383,8 @@
             except (AttributeError, TypeError):
                 return _('Study course data are incomplete.'), None
+            try:
+                schoolfees_entry = SCHOOLFEES[student.certcode]
+            except KeyError:
+                return _('School fees not yet fixed.'), None
             if student.is_postgrad and category != 'schoolfee':
                 return _("No additional fees required."), None
@@ -404,11 +403,12 @@
                     return _("You are not allowed "
                              "to pay by instalments."), None
-            # We determine the base amount first
-            if student.entry_session < 2015:
-                amount = getattr(certificate, 'school_fee_3', 0.0)
-            elif student.entry_session < 2021:
-                amount = getattr(certificate, 'school_fee_2', 0.0)
-            else:
-                amount = getattr(certificate, 'school_fee_1', 0.0)
+            additional = 0.0
+            for item in schoolfees_entry[1]:
+                try:
+                    additional += int(item)
+                except:
+                    pass
+            amount = float(schoolfees_entry[0])
+            additional -= amount
             if previous_session:
                 # Students can pay for previous sessions in all
@@ -419,5 +419,5 @@
                 # Cut school fee by 50%
                 if category in ('schoolfee_1', 'schoolfee_2') and amount:
-                    amount = gateway_net_amt(amount) / 2 + GATEWAY_AMT
+                    amount /= 2
             elif student.state == RETURNING and category != 'schoolfee_2':
                 if not student.father_name:
@@ -434,26 +434,14 @@
                 # Cut school fee by 50%
                 if category == 'schoolfee_1' and amount:
-                    amount = gateway_net_amt(amount) / 2 + GATEWAY_AMT
+                    amount /= 2
             elif category == 'schoolfee_2' and amount:
-                amount = gateway_net_amt(amount) / 2 + GATEWAY_AMT
+                amount /= 2
             else:
                 return _('Wrong state.'), None
             if amount in (0.0, None):
                 return _(u'Amount could not be determined.'), None
-            # Add Student Union Fee, Student Id Card Fee, Sports Dev. Fee,
-            # Library Dev. Fee and Welfare Assurance
-            if category in ('schoolfee_incl', 'schoolfee_1') \
-                and student.current_mode != 'ijmbe':
-                amount += gateway_net_amt(academic_session.welfare_fee) + \
-                    gateway_net_amt(academic_session.union_fee)
-                if student.entry_session >= 2018 and student.is_fresh:
-                    amount += gateway_net_amt(academic_session.sports_fee)
-                    if student.is_postgrad:
-                        amount += gateway_net_amt(academic_session.library_pg_fee)
-                    else:
-                        amount += gateway_net_amt(academic_session.library_fee)
-                if student.entry_session >= 2021 \
-                    and student.current_mode == 'ug_ft':
-                    amount += gateway_net_amt(academic_session.lms_sund_fee)
+            # Add additional fees
+            if category in ('schoolfee_incl', 'schoolfee_1'):
+                amount += additional
             # Add non-indigenous fee and session specific penalty fees
             if student.is_postgrad:
@@ -463,23 +451,4 @@
             else:
                 amount += academic_session.penalty_ug
-        #elif category == ('fac_dep'):
-        #    if student.faccode in ('FAT', 'FED', 'FLW', 'FMS', 'FSS'):
-        #        amount = 4200.0
-        #    elif student.faccode in ('FAG', 'FBM', 'FCS',
-        #                             'FES', 'FET', 'FLS', 'FPS'):
-        #        amount = 5200.0
-        #    elif student.faccode == 'FAG' and student.current_level == 400:
-        #        amount = 10200.0
-        #    elif student.depcode == 'VTE':
-        #        amount = 5200.0
-        #    if student.entry_session >= 2019:
-        #        amount += gateway_net_amt(academic_session.ict_fee)
-        elif category == 'sports_library': # temporarily in 2020
-            if student.is_postgrad:
-                amount = academic_session.sports_fee + gateway_net_amt(
-                    academic_session.library_pg_fee)
-            else:
-                amount = academic_session.sports_fee + gateway_net_amt(
-                    academic_session.library_fee)
         elif not student.is_postgrad:
             fee_name = category + '_fee'
