Index: main/waeup.sirp/trunk/src/waeup/sirp/configuration.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/configuration.py	(revision 6919)
+++ main/waeup.sirp/trunk/src/waeup/sirp/configuration.py	(revision 6920)
@@ -19,4 +19,5 @@
 import grok
 from zope.component.interfaces import IFactory
+from zope.interface import implementedBy
 from waeup.sirp.interfaces import (
     ISessionConfiguration, IConfigurationContainer, ISessionConfigurationAdd,
Index: main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py	(revision 6919)
+++ main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py	(revision 6920)
@@ -881,10 +881,11 @@
             payment.surcharge_1,
             payment.surcharge_2,
-            payment.surcharge_3)  = getPaymentDetails(
+            payment.surcharge_3,
+            error)  = getPaymentDetails(
             data['p_category'],self.context.__parent__)
-        #if payment.amount_auth == 0:
-        #    self.flash('Payment amount could not be determined.')
-        #    self.redirect(self.url(self.context, u'@@manage'))
-        #    return
+        if error:
+            self.flash(error)
+            self.redirect(self.url(self.context, u'@@manage'))
+            return
         self.context[payment.p_id] = payment
         self.flash('Payment ticket created.')
Index: main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_browser.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_browser.py	(revision 6919)
+++ main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_browser.py	(revision 6920)
@@ -34,4 +34,5 @@
 from waeup.sirp.testing import FunctionalLayer, FunctionalTestCase
 from waeup.sirp.app import University
+from waeup.sirp.configuration import SessionConfiguration
 from waeup.sirp.students.student import Student
 from waeup.sirp.university.faculty import Faculty
@@ -80,4 +81,10 @@
         # to access grok.getSite() and should get our new app then
         setSite(app)
+
+        # Set up SessionConfiguration object
+        configuration = SessionConfiguration()
+        configuration.academic_session = 2004
+        configuration.fee_1 = 20000
+        self.app['configuration'].addSessionConfiguration(configuration)
 
         # Add student with subobjects
Index: main/waeup.sirp/trunk/src/waeup/sirp/students/utils.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/students/utils.py	(revision 6919)
+++ main/waeup.sirp/trunk/src/waeup/sirp/students/utils.py	(revision 6920)
@@ -1,5 +1,5 @@
 """General helper functions for the student section.
 """
-
+from grok import getSite
 from random import SystemRandom as r
 from waeup.sirp.interfaces import academic_sessions_vocab
@@ -21,9 +21,23 @@
     return
 
-# To be defined in customization packages
+# To be specified in customization packages.
+# This function is for demonstration and testing only.
 def getPaymentDetails(category, student):
-    p_session = None
     surcharge_1 = surcharge_2 = surcharge_3 = 0
     p_item = u''
     amount = 0
-    return amount, p_item, p_session, surcharge_1, surcharge_2, surcharge_3
+    error = u''
+    p_session = student['studycourse'].current_session
+    session = str(p_session)
+    try:
+        academic_session = getSite()['configuration'][session]
+    except KeyError:
+        error = u'Session configuration object is not available.'
+        return (amount, p_item, p_session,
+            surcharge_1, surcharge_2, surcharge_3, error)
+    if category == 'schoolfee':
+        amount = academic_session.fee_1
+        surcharge_1 = academic_session.fee_2
+        p_item = student['studycourse'].certificate.code
+    return (amount, p_item, p_session,
+        surcharge_1, surcharge_2, surcharge_3, error)
