- Timestamp:
- 6 Dec 2016, 16:42:02 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py
r14306 r14315 33 33 IStudentsUtils, IStudent, IStudentRequestPW) 34 34 from waeup.kofa.students.workflow import PAID, REGISTERED, RETURNING 35 from waeup.kofa.students.studylevel import getGradeWeightFromScore36 35 from waeup.kofa.students.browser import ( 37 36 StartClearancePage, … … 81 80 ICustomCourseTicket, 82 81 ICustomStudentBase) 82 from waeup.aaue.students.studylevel import getGradeWeightFromScore 83 83 from waeup.aaue.interswitch.browser import gateway_net_amt 84 84 from waeup.aaue.interfaces import MessageFactory as _ … … 461 461 """Deliver a PDF slip of the context. 462 462 """ 463 grok.require('waeup.viewStudent')463 # grok.require('waeup.viewStudent') 464 464 465 465 note = _(""" … … 795 795 """ 796 796 797 def table_data(self, session):797 def data(self, session): 798 798 cat = queryUtility(ICatalog, name='coursetickets_catalog') 799 799 coursetickets = cat.searchResults( … … 821 821 no = 1 822 822 tickets = [] 823 passed = 0 824 failed = 0 823 825 # In AAUE only editable tickets can be printed 824 826 for ticket in sorted_tickets: … … 829 831 total = ticket.score + ticket.ca 830 832 grade = getGradeWeightFromScore(total)[0] 833 if grade == 'F': 834 failed += 1 835 else: 836 passed += 1 831 837 fullname = textwrap.fill(ticket.student.display_fullname, 30) 832 838 row = [no, … … 844 850 tickets.append(row) 845 851 no += 1 846 return header + tickets 852 total = passed + failed 853 if total: 854 passed = 100 * passed / total 855 failed = 100 * failed / total 856 return header + tickets, [passed, failed] 847 857 848 858 class DownloadPreviousSessionScoresView(DownloadScoresView):
Note: See TracChangeset for help on using the changeset viewer.