Changeset 13846 for main/waeup.aaue/trunk
- Timestamp:
- 21 Apr 2016, 14:17:19 (9 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/tests/test_utils.py
r13793 r13846 166 166 self.assertEqual(self.student.matric_number, 'AAU/SPS/ABC/dep1/04/AGRB/00001') 167 167 self.assertEqual(site['configuration'].next_matric_integer_3, 2) 168 self.student.matric_number = None 169 # students in IOE don't have a department 170 self.app['faculties']['fac1'].code = 'IOE' 171 msg, mnumber = utils.setMatricNumber(self.student) 172 self.assertEqual(self.student.matric_number, 'AAU/SPS/IOE/04/AGRB/00002') 168 173 # Diploma Students get a matric number with leading 'IOS' 169 174 # and the dp counter which is next_matric_integer_3. -
main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py
r13798 r13846 86 86 if not degree or next_integer == 0: 87 87 return _('Matriculation number cannot be set.'), None 88 if student.faccode in ('IOE'): 89 return None, "AAU/SPS/%s/%s/%s/%05d" % ( 90 faccode, year, degree, next_integer) 88 91 return None, "AAU/SPS/%s/%s/%s/%s/%05d" % ( 89 92 faccode, depcode, year, degree, next_integer)
Note: See TracChangeset for help on using the changeset viewer.