Changeset 15229 for main/waeup.aaue/trunk/src/waeup
- Timestamp:
- 11 Nov 2018, 21:22:33 (6 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
r15228 r15229 1084 1084 passed = 0 1085 1085 failed = 0 1086 with_ca = False 1086 1087 # In AAUE only editable tickets can be printed 1087 1088 for ticket in sorted_tickets: 1089 if ticket.ca > 0: 1090 with_ca = True 1088 1091 total = ticket.total_score 1089 1092 grade = ticket._getGradeWeightFromScore[0] … … 1119 1122 dep = self.context.__parent__.__parent__.longtitle 1120 1123 fac = self.context.__parent__.__parent__.__parent__.longtitle 1124 # remove CA column if not necessary 1125 if not with_ca: 1126 header = [[_(''), 1127 _('Student Id'), 1128 _('Matric No.'), 1129 #_('Reg. No.'), 1130 #_('Fullname'), 1131 #_('Status'), 1132 #_('Course of\nStudies'), 1133 _('Department'), 1134 _('Level'), 1135 #_(' CA '), 1136 _('Exam\nScore'), 1137 _('Total '), 1138 _('Grade'), 1139 ],] 1140 for ticket in tickets: 1141 del(ticket[5]) 1121 1142 return header + tickets, [ 1122 1143 dep, fac, total, passed, passed_perc, failed, failed_perc] -
main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py
r15198 r15229 424 424 open(path, 'wb').write(self.browser.contents) 425 425 print "Sample PDF coursetickets.pdf written to %s" % path 426 # The CA column is not shown if CA is not used 427 self.student['studycourse']['100']['COURSE1'].ca = 0 428 self.browser.open(pdf_url) 429 path = os.path.join(samples_dir(), 'coursetickets_wo_ca.pdf') 430 open(path, 'wb').write(self.browser.contents) 431 print "Sample PDF coursetickets_wo_ca.pdf written to %s" % path 426 432 427 433 def test_lecturers_do_only_see_selected_students(self):
Note: See TracChangeset for help on using the changeset viewer.