Better error checking with Analytics are unavailable.

This commit is contained in:
David Ormsbee
2013-03-13 15:16:36 -04:00
parent ac62fc0f66
commit e135a4052b
2 changed files with 5 additions and 1 deletions

View File

@@ -605,7 +605,7 @@ def instructor_dashboard(request, course_id):
return json.loads(res.content, object_pairs_hook=OrderedDict)
else:
log.error("Error fetching %s, code: %s, msg: %s",
(url, res.status_code, res.content))
url, res.status_code, res.content)
return None
analytics_results = {}

View File

@@ -371,6 +371,10 @@ function goto( mode)
%if modeflag.get('Analytics'):
%if not any(analytics_results.values()):
<p>No Analytics are available at this time.</p>
%endif
%if analytics_results.get("StudentsEnrolled"):
<p>
Students enrolled: