- Timestamp:
- 28 Aug 2013, 09:43:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/reports/student_reports.py
r10547 r10550 26 26 from waeup.kofa.reports import IReport 27 27 28 class IStudent sReport(IReport):28 class IStudentStatisticsReport(IReport): 29 29 30 30 session = Attribute('Session to report') … … 118 118 ] 119 119 120 @implementer(IStudent sReport)121 class Student sReport(Report):120 @implementer(IStudentStatisticsReport) 121 class StudentStatisticsReport(Report): 122 122 data = None 123 123 session = None … … 125 125 126 126 def __init__(self, session, mode, author='System'): 127 super(Student sReport, self).__init__(127 super(StudentStatisticsReport, self).__init__( 128 128 args=[session, mode], kwargs={'author':author}) 129 129 self.session = academic_sessions_vocab.getTerm(session).title … … 150 150 151 151 @implementer(IReportGenerator) 152 class Student sReportGenerator(grok.GlobalUtility):152 class StudentStatisticsReportGenerator(grok.GlobalUtility): 153 153 154 154 title = _('Students') … … 156 156 157 157 def generate(self, site, session=None, mode=None, author=None): 158 result = Student sReport(session=session, mode=mode, author=author)158 result = StudentStatisticsReport(session=session, mode=mode, author=author) 159 159 return result 160 160 … … 168 168 from waeup.kofa.reports import get_generators 169 169 grok.templatedir('browser_templates') 170 class Student sReportGeneratorPage(KofaPage):171 172 grok.context(Student sReportGenerator)170 class StudentStatisticsReportGeneratorPage(KofaPage): 171 172 grok.context(StudentStatisticsReportGenerator) 173 173 grok.name('index.html') 174 174 grok.require('waeup.manageReports') … … 215 215 return 216 216 217 class Student sReportPDFView(grok.View):218 219 grok.context(IStudent sReport)217 class StudentStatisticsReportPDFView(grok.View): 218 219 grok.context(IStudentStatisticsReport) 220 220 grok.name('pdf') 221 221 grok.require('waeup.Public') 222 222 223 223 def render(self): 224 filename = 'Student sReport_%s_%s_%s.pdf' % (224 filename = 'StudentStatisticsReport_%s_%s_%s.pdf' % ( 225 225 self.context.session, self.context.mode, 226 226 self.context.creation_dt_string)
Note: See TracChangeset for help on using the changeset viewer.