Changeset 6836 for main/waeup.sirp/trunk/src/waeup/sirp/students/student.py
- Timestamp:
- 30 Sep 2011, 08:24:05 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/students/student.py
r6830 r6836 26 26 IStudent, IStudentNavigation, IStudentClearanceEdit, 27 27 IStudentPersonalEdit) 28 from waeup.sirp.utils.helpers import attrs_to_fields 28 from waeup.sirp.utils.helpers import attrs_to_fields, get_current_principal 29 29 from waeup.sirp.students.utils import generate_student_id 30 30 … … 90 90 def getInterfaces(self): 91 91 return implementedBy(Student) 92 93 @grok.subscribe(IStudent, grok.IObjectRemovedEvent) 94 def removedStudentHandler(student, event): 95 """If a student is removed a message is logged. 96 """ 97 comment = 'Student record removed' 98 user = get_current_principal().id 99 target = student.student_id 100 grok.getSite()['students'].logger.info('%s - %s - %s' % ( 101 user, target, comment))
Note: See TracChangeset for help on using the changeset viewer.