def from_dict(klas): args = klas args['direction'] = Direction.get(id=args['direction']['id']) args['syllabus'] = Syllabus.get(id=args['syllabus']['id']) args['students'] = set(map(lambda arg: Student.get(id=arg['id']), args['students'])) return args
def get(self): student = Student.get('name') self.render('user.html', student = student)
def from_dict(old): args = old args['student'] = Student.get(id=args['student']['id']) args['topic'] = Topic.get(id=args['topic']['id']) return args