Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/tests.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/tests.py	(revision 17030)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/tests.py	(revision 17031)
@@ -59,5 +59,5 @@
         self.student.nationality = u'NG'
         self.browser.open(self.payments_path + '/addop')
-        self.browser.getControl(name="form.p_category").value = ['schoolfee_1']
+        self.browser.getControl(name="form.p_category").value = ['schoolfee']
         self.browser.getControl("Create ticket").click()
         self.assertMatches('...ticket created...',
@@ -70,5 +70,5 @@
                            self.browser.contents)
         self.assertTrue(
-            '<span>220000.0</span>' in self.browser.contents)
+            '<span>40000.0</span>' in self.browser.contents)
         self.payment_url = self.browser.url
         self.browser.getLink("Pay via Interswitch CollegePAY", index=0).click()
@@ -77,8 +77,32 @@
         self.assertEqual(self.student.current_mode, 'ug_ft')
         self.assertTrue(
-            '<input type="hidden" name="amount" value="22030000" />' in
-            self.browser.contents)
-        self.assertTrue(
-            'item_name="School Fee - 1st instalment" item_amt="22000000" bank_id="31" acct_num="1489560452"' in
+            '<input type="hidden" name="amount" value="4030000" />' in
+            self.browser.contents)
+        self.assertTrue(
+            'item_name="School Fee (total amount)" item_amt="4000000" bank_id="31" acct_num="1489560452"' in
+            self.browser.contents)
+        self.browser.open(self.payments_path + '/addop')
+        self.browser.getControl(name="form.p_category").value = ['schoolfee_1']
+        self.browser.getControl("Create ticket").click()
+        self.assertMatches('...ticket created...',
+                           self.browser.contents)
+        self.browser.open(self.payments_path)
+        ctrl = self.browser.getControl(name='val_id')
+        self.value = ctrl.options[1]
+        self.browser.getLink(self.value).click()
+        self.assertMatches('...Amount Authorized...',
+                           self.browser.contents)
+        self.assertTrue(
+            '<span>26400.0</span>' in self.browser.contents)
+        self.payment_url = self.browser.url
+        self.browser.getLink("Pay via Interswitch CollegePAY", index=0).click()
+        self.assertMatches('...<input type="hidden" name="pay_item_id" value="Default_Payable_MX26002" />...',
+                           self.browser.contents)
+        self.assertEqual(self.student.current_mode, 'ug_ft')
+        self.assertTrue(
+            '<input type="hidden" name="amount" value="2670000" />' in
+            self.browser.contents)
+        self.assertTrue(
+            'item_name="School Fee (66% - 1st instalment)" item_amt="2640000" bank_id="31" acct_num="1489560452"' in
             self.browser.contents)
 
Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/utils.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/utils.py	(revision 17030)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/utils.py	(revision 17031)
@@ -60,34 +60,46 @@
             return _(u'Session configuration object is not available.'), None
         # Determine fee.
-        if category in ('schoolfee_1', 'secondinstal'):
-            if student.state == CLEARED:
-                pass
-            elif student.state == RETURNING:
-                # In case of returning school fee payment the
-                # payment session and level contain the values of
-                # the session the student has paid for. Payment
-                # session is always next session.
-                p_session, p_level = self.getReturningData(student)
-                academic_session = self._getSessionConfiguration(p_session)
-                if academic_session == None:
-                    return _(
-                        u'Session configuration object is not available.'
-                        ), None
-            elif student.is_postgrad and student.state == PAID:
-                # Returning postgraduate students also pay for the
-                # next session but their level always remains the
-                # same.
-                p_session += 1
-                academic_session = self._getSessionConfiguration(p_session)
-                if academic_session == None:
-                    return _(
-                        u'Session configuration object is not available.'
-                        ), None
+        if category in ('schoolfee', 'schoolfee_1', 'secondinstal'):
+            try:
+                certificate = student['studycourse'].certificate
+                p_item = certificate.code
+            except (AttributeError, TypeError):
+                return _('Study course data are incomplete.'), None
+            if previous_session:
+                # Students can pay for previous sessions in all
+                # workflow states.  Fresh students are excluded by the
+                # update method of the PreviousPaymentAddFormPage.
+                amount = getattr(certificate, 'school_fee_1', 0.0)
             else:
-                return _('School fee payment not allowed. Wrong state.'), None
-            if category == 'schoolfee_1':
-                amount = 220000.0
-            elif category == 'secondinstal':
-                amount = 100000.0
+                if category == 'secondinstal':
+                    amount = 0.34 * getattr(certificate, 'school_fee_1', 0.0)
+                else:
+                    if student.state == CLEARED:
+                        amount = getattr(certificate, 'school_fee_1', 0.0)
+                    elif student.state == RETURNING:
+                        # In case of returning school fee payment the
+                        # payment session and level contain the values of
+                        # the session the student has paid for. Payment
+                        # session is always next session.
+                        p_session, p_level = self.getReturningData(student)
+                        academic_session = self._getSessionConfiguration(p_session)
+                        if academic_session == None:
+                            return _(
+                                u'Session configuration object is not available.'
+                                ), None
+                        amount = getattr(certificate, 'school_fee_1', 0.0)
+                    elif student.is_postgrad and student.state == PAID:
+                        # Returning postgraduate students also pay for the
+                        # next session but their level always remains the
+                        # same.
+                        p_session += 1
+                        academic_session = self._getSessionConfiguration(p_session)
+                        if academic_session == None:
+                            return _(
+                                u'Session configuration object is not available.'
+                                ), None
+                        amount = getattr(certificate, 'school_fee_1', 0.0)
+                    if category == 'schoolfee_1':
+                        amount *= 0.66
         elif category == 'clearance':
             try:
Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/utils/utils.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/utils/utils.py	(revision 17030)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/utils/utils.py	(revision 17031)
@@ -26,6 +26,6 @@
     PAYMENT_CATEGORIES = {
         'schoolfee': 'School Fee (total amount)',
-        'schoolfee_1': 'School Fee - 1st instalment',
-        'secondinstal': 'School Fee - 2nd instalment',
+        'schoolfee_1': 'School Fee (66% - 1st instalment)',
+        'secondinstal': 'School Fee (34% - 2nd instalment)',
         'clearance': 'Acceptance Fee',
         'hostel':'Hostel Fee',
@@ -42,7 +42,7 @@
 
     SELECTABLE_PAYMENT_CATEGORIES = {
-        #'schoolfee': 'School Fee (total amount)',
-        'schoolfee_1': 'School Fee - 1st instalment',
-        'secondinstal': 'School Fee - 2nd instalment',
+        'schoolfee': 'School Fee (total amount)',
+        'schoolfee_1': 'School Fee (66% - 1st instalment)',
+        'secondinstal': 'School Fee (34% - 2nd instalment)',
         'hostel':'Hostel Fee',
         }
