Index: main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py	(revision 8518)
+++ main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py	(revision 8524)
@@ -22,5 +22,4 @@
 import sys
 import grok
-from time import time
 from datetime import datetime, date
 from zope.event import notify
@@ -534,19 +533,5 @@
     factory = u'waeup.ApplicantOnlinePayment'
 
-    def _fillCustomFields(self, payment, session_config):
-        """No custom fields in the base package
-        """
-        return payment
-
     def update(self):
-        p_category = 'application'
-        session = str(self.context.__parent__.year)
-        try:
-            session_config = grok.getSite()['configuration'][session]
-        except KeyError:
-            self.flash(_('Session configuration object is not available.'))
-            self.redirect(self.url(self.context))
-            return
-        timestamp = "%d" % int(time()*1000)
         for key in self.context.keys():
             ticket = self.context[key]
@@ -556,11 +541,12 @@
                   self.redirect(self.url(self.context))
                   return
+        applicants_utils = getUtility(IApplicantsUtils)
+        container = self.context.__parent__
         payment = createObject(self.factory)
-        payment.p_id = "p%s" % timestamp
-        payment.p_item = self.context.__parent__.title
-        payment.p_session = self.context.__parent__.year
-        payment.p_category = p_category
-        payment.amount_auth = session_config.application_fee
-        payment = self._fillCustomFields(payment, session_config)
+        error = applicants_utils.setPaymentDetails(container, payment)
+        if error is not None:
+            self.flash(error)
+            self.redirect(self.url(self.context))
+            return
         self.context[payment.p_id] = payment
         self.flash(_('Payment ticket created.'))
Index: main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_browser.py	(revision 8518)
+++ main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_browser.py	(revision 8524)
@@ -87,4 +87,5 @@
         applicantscontainer.prefix = 'app'
         applicantscontainer.year = 2009
+        applicantscontainer.title = u'This is the app2009 container'
         applicantscontainer.application_category = 'basic'
         applicantscontainer.mode = 'create'
@@ -692,4 +693,10 @@
                            self.browser.contents)
         payment_url = self.browser.url
+        payment_id = self.applicant.keys()[0]
+        payment = self.applicant[payment_id]
+        self.assertEqual(payment.p_item,'This is the app2009 container')
+        self.assertEqual(payment.p_session,2009)
+        self.assertEqual(payment.p_category,'application')
+        self.assertEqual(payment.amount_auth,200.0)
         # The pdf payment slip can't yet be opened
         #self.browser.open(payment_url + '/payment_receipt.pdf')
@@ -701,6 +708,4 @@
             Unauthorized, self.browser.open, payment_url + '/approve')
         # We approve the payment by bypassing the view
-        payment_id = self.applicant.keys()[0]
-        payment = self.applicant[payment_id]
         payment.approve()
         # The payment slip can be downloaded now
Index: main/waeup.kofa/trunk/src/waeup/kofa/applicants/utils.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/applicants/utils.py	(revision 8518)
+++ main/waeup.kofa/trunk/src/waeup/kofa/applicants/utils.py	(revision 8524)
@@ -19,4 +19,5 @@
 """
 
+from time import time
 import grok
 from waeup.kofa.applicants.interfaces import IApplicantsUtils
@@ -36,2 +37,18 @@
       'form.screening_score': _(u'Process Data'),
       }
+
+    def setPaymentDetails(self, container, payment):
+        """Set the payment data of an applicant.
+        """
+        timestamp = "%d" % int(time()*1000)
+        session = str(container.year)
+        try:
+            session_config = grok.getSite()['configuration'][session]
+        except KeyError:
+            return _(u'Session configuration object is not available.')
+        payment.p_id = "p%s" % timestamp
+        payment.p_item = container.title
+        payment.p_session = container.year
+        payment.p_category = 'application'
+        payment.amount_auth = session_config.application_fee
+        return None
