Changeset 16027 for main/waeup.kofa/trunk/src/waeup/kofa
- Timestamp:
- 6 Mar 2020, 19:56:56 (5 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/studylevel.py
r16024 r16027 27 27 from zope.component import createObject, queryUtility, getUtility 28 28 from zope.interface import implementedBy 29 from zope.event import notify 29 30 from waeup.kofa.interfaces import academic_sessions_vocab, VALIDATED, IKofaUtils 30 31 from waeup.kofa.students.interfaces import ( … … 33 34 from waeup.kofa.students.vocabularies import StudyLevelSource 34 35 from waeup.kofa.interfaces import MessageFactory as _ 36 37 @grok.subscribe(IStudentStudyLevel, grok.IObjectModifiedEvent) 38 def handle_update_coursetickets(studylevel, event): 39 """If level_session has changed, coursetickets_catalog 40 must be informed. 41 """ 42 # Catalog must be informed 43 for ticket in studylevel.values(): 44 notify(grok.ObjectModifiedEvent(ticket)) 45 return 35 46 36 47 def find_carry_over(ticket): -
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r16007 r16027 4474 4474 self.app['users']['mrslecturer'].title = u'Mercedes Benz' 4475 4475 # Add course ticket 4476 s tudylevel = createObject(u'waeup.StudentStudyLevel')4477 s tudylevel.level = 1004478 s tudylevel.level_session = 20044476 self.studylevel = createObject(u'waeup.StudentStudyLevel') 4477 self.studylevel.level = 100 4478 self.studylevel.level_session = 2004 4479 4479 self.student['studycourse'].addStudentStudyLevel( 4480 self.certificate, s tudylevel)4480 self.certificate, self.studylevel) 4481 4481 # Assign local Lecturer role for a course. 4482 4482 course = self.app['faculties']['fac1']['dep1'].courses['COURSE1'] … … 4626 4626 self.assertTrue( 4627 4627 self.browser.getControl(name="scores:list") is not None) 4628 # if level_session of studycourse changes, catalog has been updated 4629 # and student disappears 4630 self.studylevel.level_session = 2005 4631 self.browser.reload() 4632 self.assertRaises( 4633 LookupError, self.browser.getControl, name="scores") 4628 4634 4629 4635 def test_score_editing_can_change_scores(self):
Note: See TracChangeset for help on using the changeset viewer.