Changeset 8820
- Timestamp:
- 27 Jun 2012, 07:15:21 (12 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa/students
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/interfaces.py
r8779 r8820 42 42 def getValues(self, context): 43 43 verdicts_dict = getUtility(IStudentsUtils).VERDICTS_DICT 44 return verdicts_dict.keys()44 return sorted(verdicts_dict.keys()) 45 45 46 46 def getToken(self, context, value): … … 49 49 def getTitle(self, context, value): 50 50 verdicts_dict = getUtility(IStudentsUtils).VERDICTS_DICT 51 if value != '0': 52 return verdicts_dict[value] + ' (%s)' % value 51 53 return verdicts_dict[value] 52 54 … … 345 347 title = _(u'Current Verdict'), 346 348 source = VerdictSource(), 347 default = ' NY',349 default = '0', 348 350 required = False, 349 351 ) … … 352 354 title = _(u'Previous Verdict'), 353 355 source = VerdictSource(), 354 default = ' NY',356 default = '0', 355 357 required = False, 356 358 ) … … 396 398 title = _(u'Verdict'), 397 399 source = VerdictSource(), 398 default = ' NY',400 default = '0', 399 401 required = False, 400 402 ) -
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r8779 r8820 754 754 self.assertEqual(student['studycourse'].current_session, 2005) # +1 755 755 self.assertEqual(student['studycourse'].current_level, 200) # +100 756 self.assertEqual(student['studycourse'].current_verdict, ' NY') # NY= not set756 self.assertEqual(student['studycourse'].current_verdict, '0') # 0 = Zero = not set 757 757 self.assertEqual(student['studycourse'].previous_verdict, 'A') 758 758 self.browser.getControl(name="transition").value = ['register_courses'] -
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_export.py
r8621 r8820 127 127 'entry_mode,entry_session,previous_verdict,student_id\r\n' 128 128 129 ',,, NY,,,NY,\r\n'129 ',,,0,,,0,\r\n' 130 130 ) 131 131 return … … 144 144 'entry_mode,entry_session,previous_verdict,student_id\r\n' 145 145 146 'CERT1,200,2012, NY,ug_ft,2010,NY,A111111\r\n'146 'CERT1,200,2012,0,ug_ft,2010,0,A111111\r\n' 147 147 ) 148 148 return … … 160 160 'entry_mode,entry_session,previous_verdict,student_id\r\n' 161 161 162 'CERT1,200,2012, NY,ug_ft,2010,NY,A111111\r\n'162 'CERT1,200,2012,0,ug_ft,2010,0,A111111\r\n' 163 163 ) 164 164 return … … 175 175 'entry_mode,entry_session,previous_verdict,student_id\r\n' 176 176 177 'CERT1,200,2012, NY,ug_ft,2010,NY,A111111\r\n'177 'CERT1,200,2012,0,ug_ft,2010,0,A111111\r\n' 178 178 ) 179 179 return … … 210 210 result, 211 211 'level,level_session,level_verdict,student_id\r\n' 212 ',, NY,\r\n'212 ',,0,\r\n' 213 213 ) 214 214 return -
main/waeup.kofa/trunk/src/waeup/kofa/students/utils.py
r8708 r8820 250 250 student['studycourse'].current_session = new_session 251 251 verdict = student['studycourse'].current_verdict 252 student['studycourse'].current_verdict = ' NY'252 student['studycourse'].current_verdict = '0' 253 253 student['studycourse'].previous_verdict = verdict 254 254 return … … 412 412 413 413 VERDICTS_DICT = { 414 ' NY': _('(not yet)'),414 '0': _('(not yet)'), 415 415 'A': 'Successful student', 416 416 'B': 'Student with carryover courses',
Note: See TracChangeset for help on using the changeset viewer.