def log_coach_report_view(request):
 if ('facility_user' in request.session):
  try:
   user = request.session['facility_user']
   UserLog.begin_user_activity(user, activity_type='coachreport')
   UserLog.update_user_activity(user, activity_type='login')
   UserLog.end_user_activity(user, activity_type='coachreport')
  except ValidationError as e:
   logging.error(('Failed to update Teacher userlog activity login: %s' % e))

def log_coach_report_view ( request ) : if ( 'facility_user' in request . session ) : try : user = request . session [ 'facility_user' ] UserLog . begin_user_activity ( user , activity_type = 'coachreport' ) UserLog . update_user_activity ( user , activity_type = 'login' ) UserLog . end_user_activity ( user , activity_type = 'coachreport' ) except ValidationError as e : logging . error ( ( 'Failed to update Teacher userlog activity login: %s' % e ) )
record coach report view by teacher .