- Timestamp:
- 26 May 2014, 13:35:27 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/webservices.py
r10521 r11667 228 228 lastname=student.lastname, 229 229 ) 230 231 @grok.require('waeup.getBiometricData') 232 def get_student_fingerprints(self, identifier=None): 233 """Returns student fingerprint data if available. 234 """ 235 students = self.context['students'] 236 student = get_student(students, identifier) 237 if student is None: 238 return dict() 239 result = dict( 240 email=student.email, 241 firstname=student.firstname, 242 lastname=student.lastname, 243 img=None, 244 fingerprints={}, 245 ) 246 file_store = getUtility(IExtFileStore) 247 for num in [str(x+1) for x in range(10)]: 248 fp_file = getUtility(IExtFileStore).getFileByContext( 249 student, attr='%s.fpm' % num) 250 if fp_file is not None: 251 result.append(xmlrpclib.Binary(fp_file.read())) 252 return result
Note: See TracChangeset for help on using the changeset viewer.