Ignore:
Timestamp:
17 Nov 2012, 07:15:04 (12 years ago)
Author:
Henrik Bettermann
Message:

It's not a report of a single student but a report of subsets of students.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/students/reports.py

    r9652 r9653  
    2626from waeup.kofa.reports import IReport
    2727
    28 class IStudentReport(IReport):
     28class IStudentsReport(IReport):
    2929    pass
    3030
     
    112112    ]
    113113
    114 @implementer(IStudentReport)
    115 class StudentReport(Report):
     114@implementer(IStudentsReport)
     115class StudentsReport(Report):
    116116    data = None
    117117    session = None
     
    119119
    120120    def __init__(self, session, mode, author='System'):
    121         super(StudentReport, self).__init__(
     121        super(StudentsReport, self).__init__(
    122122            args=[session, mode], kwargs={'author':author})
    123123        self.session = academic_sessions_vocab.getTerm(session).title
     
    127127
    128128    def __repr__(self):
    129         return 'StudentReport (session=%s, mode=%s)' % (
     129        return 'StudentsReport (session=%s, mode=%s)' % (
    130130            self.session, self.mode)
    131131
     
    152152
    153153@implementer(IReportGenerator)
    154 class StudentReportGenerator(grok.GlobalUtility):
     154class StudentsReportGenerator(grok.GlobalUtility):
    155155
    156156    title = _('Students')
     
    162162
    163163    def generate(self, site, session=None, mode=None, author=None):
    164         result = StudentReport(session=session, mode=mode, author=author)
     164        result = StudentsReport(session=session, mode=mode, author=author)
    165165        return result
    166166
     
    174174from waeup.kofa.reports import get_generators
    175175grok.templatedir('browser_templates')
    176 class StudentReportGeneratorPage(KofaPage):
    177 
    178     grok.context(StudentReportGenerator)
     176class StudentsReportGeneratorPage(KofaPage):
     177
     178    grok.context(StudentsReportGenerator)
    179179    grok.name('index.html')
    180180    grok.require('waeup.manageReports')
     
    219219        return
    220220
    221 class StudentReportPDFView(grok.View):
    222 
    223     grok.context(IStudentReport)
     221class StudentsReportPDFView(grok.View):
     222
     223    grok.context(IStudentsReport)
    224224    grok.name('pdf')
    225225    grok.require('waeup.Public')
Note: See TracChangeset for help on using the changeset viewer.