Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/browser.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/browser.py	(revision 17344)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/interswitch/browser.py	(revision 17345)
@@ -164,5 +164,4 @@
         xmldict['institution_bank_id'] = '31'
         if self.context.__parent__.__parent__.prefix.startswith('tsc'):
-            provider_amt = 2000.0
             midwife_amt = 0.0
             xmldict['institution_acct'] = '1000907711'
@@ -195,9 +194,15 @@
 </item_details>
 </payment_item_detail>""" % xmldict
+        elif not provider_amt and midwife_amt:
+            xmltext = """<payment_item_detail>
+<item_details detail_ref="%(detail_ref)s" college="%(institution_name)s">
+<item_detail item_id="1" item_name="%(institution_item_name)s" item_amt="%(institution_amt)d" bank_id="%(institution_bank_id)s" acct_num="%(institution_acct)s" />
+<item_detail item_id="2" item_name="Nursing and Midwifery Committee" item_amt="%(midwife_amt)d" bank_id="8" acct_num="2004854377" />
+</item_details>
+</payment_item_detail>""" % xmldict
         else:
             xmltext = """<payment_item_detail>
 <item_details detail_ref="%(detail_ref)s" college="%(institution_name)s">
 <item_detail item_id="1" item_name="%(institution_item_name)s" item_amt="%(institution_amt)d" bank_id="%(institution_bank_id)s" acct_num="%(institution_acct)s" />
-<item_detail item_id="2" item_name="Nursing and Midwifery Committee" item_amt="%(midwife_amt)d" bank_id="8" acct_num="2004854377" />
 </item_details>
 </payment_item_detail>""" % xmldict
Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser.py	(revision 17344)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser.py	(revision 17345)
@@ -30,5 +30,8 @@
     StudyLevelEditFormPage, StudyLevelDisplayFormPage,
     StudentBasePDFFormPage, ExportPDFCourseRegistrationSlip,
-    CourseTicketDisplayFormPage, StudentTriggerTransitionFormPage,
+    CourseTicketDisplayFormPage,
+    CourseTicketManageFormPage,
+    StudyLevelDisplayFormPage,
+    StudentTriggerTransitionFormPage,
     ExportPDFAdmissionSlip, StartClearancePage, PaymentsManageFormPage,
     BalancePaymentAddFormPage, msave, emit_lock_message)
@@ -48,6 +51,38 @@
 from kofacustom.edocons.students.interfaces import (
     ICustomStudentOnlinePayment, ICustomStudentStudyCourse,
-    ICustomStudentStudyLevel)
+    ICustomStudentStudyLevel, ICustomCourseTicket)
 from kofacustom.edocons.interfaces import MessageFactory as _
+
+def translated_values(view):
+    """Translate course ticket attribute values to be displayed on
+    studylevel pages.
+    """
+    lang = view.request.cookies.get('kofa.language')
+    for value in view.context.values():
+        # We have to unghostify (according to Tres Seaver) the __dict__
+        # by activating the object, otherwise value_dict will be empty
+        # when calling the first time.
+        value._p_activate()
+        value_dict = dict([i for i in value.__dict__.items()])
+        value_dict['url'] = view.url(value)
+        value_dict['removable_by_student'] = value.removable_by_student
+        value_dict['mandatory'] = translate(str(value.mandatory), 'zope',
+            target_language=lang)
+        value_dict['carry_over'] = translate(str(value.carry_over), 'zope',
+            target_language=lang)
+        value_dict['outstanding'] = translate(str(value.outstanding), 'zope',
+            target_language=lang)
+        value_dict['automatic'] = translate(str(value.automatic), 'zope',
+            target_language=lang)
+        value_dict['grade'] = value.grade
+        value_dict['weight'] = value.weight
+        value_dict['course_category'] = value.course_category
+        value_dict['total_score'] = value.total_score
+        semester_dict = getUtility(IKofaUtils).SEMESTER_DICT
+        value_dict['semester'] = semester_dict[
+            value.semester].replace('mester', 'm.')
+        # ECNS specific
+        value_dict['carryover_score'] = value.carryover_score
+        yield value_dict
 
 class CustomStartClearancePage(StartClearancePage):
@@ -118,2 +153,27 @@
 class CustomBedTicketAddPage(NigeriaBedTicketAddPage):
     with_ac = False
+
+class CustomStudyLevelDisplayFormPage(StudyLevelDisplayFormPage):
+    """ Page to display student study levels
+    """
+    @property
+    def translated_values(self):
+        return translated_values(self)
+
+        
+class CustomCourseTicketDisplayFormPage(CourseTicketDisplayFormPage):
+    """ Page to display course tickets
+    """
+    form_fields = grok.AutoFields(ICustomCourseTicket).omit('course_category',
+        'ticket_session')
+
+    @property
+    def form_fields(self):
+        if not self.context.carry_over:
+            return grok.AutoFields(ICustomCourseTicket).omit('carryover_score')
+        return grok.AutoFields(ICustomCourseTicket)
+
+class CustomCourseTicketManageFormPage(CourseTicketManageFormPage):
+    """ Page to manage course tickets
+    """
+    form_fields = grok.AutoFields(ICustomCourseTicket)
Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser_templates/studylevelpage.pt
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser_templates/studylevelpage.pt	(revision 17345)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/browser_templates/studylevelpage.pt	(revision 17345)
@@ -0,0 +1,68 @@
+<table class="form-table" i18n:domain="waeup.kofa">
+  <tbody>
+    <tal:block repeat="widget view/widgets">
+      <tr>
+        <td class="fieldname">
+          <span tal:content="widget/label">label</span>:
+        </td>
+        <td tal:on-error="default">
+          <div tal:content="structure widget">
+            <input type="text" />
+          </div>
+        </td>
+      </tr>
+    </tal:block>
+  </tbody>
+</table>
+
+<h3 i18n:domain="waeup.kofa" i18n:translate="">Course Tickets</h3>
+
+<table class="kofa-data-table dataTable" i18n:domain="waeup.kofa">
+  <thead>
+    <tr>
+      <th i18n:translate="">Term</th>
+      <th i18n:translate="">Code</th>
+      <th i18n:translate="">Title</th>
+      <th i18n:translate="">Dep.</th>
+      <th i18n:translate="">Fac.</th>
+      <th i18n:translate="">Cred.</th>
+      <th i18n:translate="">Requ.</th>
+      <th i18n:translate="">Score</th>
+      <th i18n:translate="">Grade</th>
+      <th i18n:translate="">RST</th>
+      <th i18n:translate="">OS</th>
+      <th i18n:translate="">Auto</th>
+    </tr>
+  </thead>
+  <tbody>
+    <tr tal:repeat="value view/translated_values">
+      <td tal:content="value/semester" nowrap>TERM</td>
+      <td> <a tal:attributes="href value/url">
+      <span tal:content="value/code">CODE</span>
+      </a></td>
+      <td tal:content="value/title">TITLE</td>
+      <td tal:content="value/dcode">DEPARTMENT</td>
+      <td tal:content="value/fcode">FACULTY</td>
+      <td tal:content="value/credits">CREDITS</td>
+      <td tal:content="value/mandatory">MANDATORY</td>
+      <td tal:content="value/score|nothing">SCORE</td>
+      <td tal:content="value/grade|nothing">GRADE</td>
+      <td tal:content="value/carryover_score">RSTSCORE</td>
+      <td tal:content="value/outstanding">OS</td>
+      <td tal:content="value/automatic">AUTO</td>
+    </tr>
+  </tbody>
+</table>
+
+<p i18n:domain="waeup.kofa"
+   i18n:translate="course_types">
+  RST: Result to resit<br />
+  OS: Outstanding course<br />
+  Requ.: Required course<br />
+  Auto: Automatically created course ticket
+</p>
+
+<div i18n:domain="waeup.kofa"
+  tal:condition="python: not len(context.keys())" i18n:translate="">
+  The're no tickets added yet.
+</div>
Index: /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/interfaces.py
===================================================================
--- /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/interfaces.py	(revision 17344)
+++ /main/kofacustom.edocons/trunk/src/kofacustom/edocons/students/interfaces.py	(revision 17345)
@@ -92,4 +92,14 @@
     """
 
+    carryover_score = schema.Int(
+        title = _(u'Carry-over Score'),
+        default = None,
+        required = False,
+        missing_value = None,
+        max = 100,
+        )
+
+ICustomCourseTicket['carryover_score'].order = ICustomCourseTicket['carry_over'].order
+
 class ICustomStudentUpdateByRegNo(INigeriaStudentUpdateByRegNo):
     """Representation of a student. Skip regular reg_number validation.
