Changeset 14165 for main/waeup.aaue/trunk
- Timestamp:
- 6 Sep 2016, 18:37:59 (8 years ago)
- Location:
- main/waeup.aaue/trunk/src/waeup/aaue/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py
r14149 r14165 47 47 CourseTicketManageFormPage, 48 48 EditScoresPage, 49 ExportPDFScoresSlip 49 ExportPDFScoresSlip, 50 StudyCourseTranscriptPage, 50 51 ) 51 52 from kofacustom.nigeria.students.browser import ( … … 63 64 NigeriaAccommodationManageFormPage, 64 65 NigeriaStudentBaseDisplayFormPage, 65 NigeriaStudentBaseManageFormPage, 66 NigeriaExportPDFFinancialClearancePage 66 NigeriaStudentBaseManageFormPage 67 67 ) 68 68 from waeup.aaue.students.interfaces import ( … … 411 411 ) 412 412 413 class CustomStudyCourseTranscriptPage(StudyCourseTranscriptPage): 414 """ Page to display the student's transcript. 415 """ 416 grok.require('waeup.viewStudent') 417 413 418 class CustomExportPDFTranscriptSlip(ExportPDFTranscriptSlip): 414 419 """Deliver a PDF slip of the context. 415 420 """ 421 grok.require('waeup.viewStudent') 416 422 417 423 def _sigsInFooter(self): … … 780 786 return header + sorted(tickets, 781 787 key=lambda value: value[5] + value[3] + str(value[6])) 782 783 784 785 class CustomExportPDFFinancialClearancePage(NigeriaExportPDFFinancialClearancePage):786 """Deliver a PDF financial clearance slip.787 """788 789 def _sigsInFooter(self):790 if not checkPermission('waeup.clearStudentFinancially', self.context):791 return ()792 return (_('Date, Checking Officer Signature'),793 _('Date, Approving Officer Signature'),794 ) -
main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py
r14136 r14165 867 867 self.assertTrue('mrslecturer - waeup.aaue.students.browser.CustomEditScoresPage - ' 868 868 'E1000000 100/COURSE1 score updated (None)' in logcontent) 869 870 871 def test_student_view_transcript(self): 872 # Student cant login if their password is not set 873 IWorkflowInfo(self.student).fireTransition('admit') 874 self.browser.open(self.login_path) 875 self.browser.getControl(name="form.login").value = self.student_id 876 self.browser.getControl(name="form.password").value = 'spwd' 877 self.browser.getControl("Login").click() 878 self.assertMatches( 879 '...You logged in...', self.browser.contents) 880 # Students can view the transcript 881 self.browser.open(self.studycourse_path) 882 self.browser.getLink("Transcript").click() 883 self.browser.getLink("Academic Transcript").click() 884 self.assertEqual(self.browser.headers['Status'], '200 Ok') 885 self.assertEqual(self.browser.headers['Content-Type'], 'application/pdf')
Note: See TracChangeset for help on using the changeset viewer.