Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 13764)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 13766)
@@ -3422,10 +3422,20 @@
 
     def _set_exporter_values(self):
-        # We provide only two exporters.
+        # We provide only the 'lecturer' exporter but can add more.
         exporters = []
-        for name in ('students', 'coursetickets'):
+        for name in ('lecturer',):
             util = getUtility(ICSVExporter, name=name)
             exporters.append((util.title, name),)
         self.exporters = exporters
+
+    def _set_session_values(self):
+        # We allow only current academic session
+        academic_session = grok.getSite()['configuration'].current_academic_session
+        if not academic_session:
+            self.sessions = []
+            return
+        x = academic_sessions_vocab.getTerm(academic_session)
+        self.sessions = [(x.title, x.token)]
+        return
 
     def update(self, START=None, session=None, level=None, mode=None,
@@ -3435,4 +3445,11 @@
         self._set_mode_values()
         self._set_exporter_values()
+        if not self.sessions:
+            self.flash(
+                _('Academic session not set. '
+                  'Please contact the administrator.'),
+                type='danger')
+            self.redirect(self.url(self.context))
+            return
         if START is None:
             return
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/export.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/export.py	(revision 13764)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/export.py	(revision 13766)
@@ -349,4 +349,24 @@
             value, name, context=context)
 
+class DataForLecturerExporter(CourseTicketExporter):
+    """
+    """
+    grok.name('lecturer')
+
+    fields = ('matric_number', 'reg_number', 'student_id', 'display_fullname',
+              'level', 'code', 'level_session', 'score')
+
+    title = _(u'Data for Lecturer')
+
+    def mangle_value(self, value, name, context=None):
+        """The mangler determines the student's id and fullname.
+        """
+        if context is not None:
+            student = context.student
+            if name in ('student_id', 'fullname') and student is not None:
+                value = getattr(student, name, None)
+        return super(
+            CourseTicketExporter, self).mangle_value(
+            value, name, context=context)
 
 class StudentPaymentExporter(grok.GlobalUtility, StudentExporterBase):
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py	(revision 13764)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py	(revision 13766)
@@ -3755,5 +3755,5 @@
             )
 
-    def test_course_export_students(self):
+    def deprecated_test_course_export_students(self):
         self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')
         course1_path = 'http://localhost/app/faculties/fac1/dep1/courses/COURSE1'
@@ -3801,5 +3801,5 @@
             )
 
-    def test_course_export_coursetickets(self):
+    def test_course_export_lecturer(self):
         # We add study level 100 to the student's studycourse
         studylevel = StudentStudyLevel()
@@ -3813,5 +3813,10 @@
         self.browser.getLink("Export student data").click()
         self.browser.getControl("Configure new export").click()
-        self.browser.getControl(name="exporter").value = ['coursetickets']
+        self.assertTrue(
+            'Academic session not set. Please contact the administrator.'
+            in self.browser.contents)
+        self.app['configuration'].current_academic_session = 2004
+        self.browser.getControl("Configure new export").click()
+        self.browser.getControl(name="exporter").value = ['lecturer']
         self.browser.getControl(name="session").value = ['2004']
         self.browser.getControl(name="level").value = ['100']
@@ -3825,14 +3830,10 @@
             'text/csv; charset=UTF-8')
         self.assertTrue(
-            'filename="WAeUP.Kofa_coursetickets_%s.csv' % job_id in
+            'filename="WAeUP.Kofa_lecturer_%s.csv' % job_id in
             self.browser.headers['content-disposition'])
         # ... and contains the course ticket COURSE1
         self.assertEqual(self.browser.contents,
-            'automatic,carry_over,code,credits,dcode,fcode,level,'
-            'level_session,mandatory,passmark,score,semester,title,'
-            'student_id,certcode,display_fullname\r\n1,0,COURSE1,10,'
-            'dep1,fac1,100,2004,1,40,,1,'
-            'Unnamed Course,K1000000,CERT1,Anna Tester\r\n')
-
+            'matric_number,reg_number,student_id,display_fullname,level,code,'
+            'level_session,score\r\n,,K1000000,,100,COURSE1,2004,\r\n')
         self.assertEqual(len(self.app['datacenter'].running_exports), 1)
         job_id = self.app['datacenter'].running_exports[0][0]
@@ -3847,10 +3848,10 @@
         self.assertTrue(
             'zope.mgr - students.browser.CourseExportJobContainerJobConfig '
-            '- exported: coursetickets (2004, 100, COURSE1), job_id=%s'
+            '- exported: lecturer (2004, 100, COURSE1), job_id=%s'
             % job_id in logcontent
             )
         self.assertTrue(
             'zope.mgr - students.browser.ExportJobContainerDownload '
-            '- downloaded: WAeUP.Kofa_coursetickets_%s.csv, job_id=%s'
+            '- downloaded: WAeUP.Kofa_lecturer_%s.csv, job_id=%s'
             % (job_id, job_id) in logcontent
             )
