Index: /WAeUP_SRP/trunk/skins/waeup_epayment/epayment_cb.py
===================================================================
--- /WAeUP_SRP/trunk/skins/waeup_epayment/epayment_cb.py	(revision 1302)
+++ /WAeUP_SRP/trunk/skins/waeup_epayment/epayment_cb.py	(revision 1303)
@@ -18,5 +18,5 @@
 request = context.REQUEST
 students = context.portal_url.getPortalObject().campus.students
-
+wftool = context.portal_workflow
 student_id = context.getStudentId()
 if student_id is None:
@@ -41,3 +41,6 @@
     pd[pdk] = request.get(rc)
 context.getContent().edit(mapping=pd)
+wftool.doActionFor(student,'pay_school_fee')
+wftool.doActionFor(context,'close')
+
 return request.RESPONSE.redirect("%s/waeup_document_view" % context.absolute_url()) 
Index: /WAeUP_SRP/trunk/skins/waeup_epayment/pay_by_sc.py
===================================================================
--- /WAeUP_SRP/trunk/skins/waeup_epayment/pay_by_sc.py	(revision 1302)
+++ /WAeUP_SRP/trunk/skins/waeup_epayment/pay_by_sc.py	(revision 1303)
@@ -30,5 +30,5 @@
                                      id = sbrain.course)
 if not res:
-    logger.info('"%s","certificate not found", "%s"' % (student_id,course))
+    logger.info('"%s","certificate not found", "%s"' % (student_id,sbrain.course))
     prefix = ""
 else:
Index: /WAeUP_SRP/trunk/skins/waeup_epayment/pay_online.py
===================================================================
--- /WAeUP_SRP/trunk/skins/waeup_epayment/pay_online.py	(revision 1302)
+++ /WAeUP_SRP/trunk/skins/waeup_epayment/pay_online.py	(revision 1303)
@@ -17,4 +17,5 @@
 import DateTime
 request = context.REQUEST
+wftool = context.portal_workflow
 students = context.portal_url.getPortalObject().campus.students
 
@@ -64,8 +65,11 @@
 payments.invokeFactory('Payment', p_id)
 payment = getattr(payments,p_id)
+wftool.doActionFor(payment,'open')
 d = {}
 d.update(info)
 #from Products.zdb import set_trace;set_trace()
 payment.getContent().edit(mapping=d)
+wftool.doActionFor(payment,'close')
+wftool.doActionFor(student,'pay_school_fee')
 info['callback_url'] = "%s/payments/%s/epayment_cb" % (student.absolute_url(),p_id)
 if context.portal_url().find('uniben-demo.waeup.org') >-1 or\
@@ -93,3 +97,2 @@
 url = info['action'] + "?" + urlencode(args)
 request.RESPONSE.redirect(url)
-
Index: /WAeUP_SRP/trunk/skins/waeup_pins/batch_view.pt
===================================================================
--- /WAeUP_SRP/trunk/skins/waeup_pins/batch_view.pt	(revision 1302)
+++ /WAeUP_SRP/trunk/skins/waeup_pins/batch_view.pt	(revision 1303)
@@ -28,5 +28,5 @@
         <span tal:replace="info/batch_doc/no_of_pins" /></h3>
         <span tal:replace="structure rendered" />
-        <table>
+        <table tal:condition="nothing">
           <tr tal:repeat="pin info/used">
             <td tal:content="python:path('repeat/pin/index')+1" />
