diff --git a/common/lib/capa/capa/responsetypes.py b/common/lib/capa/capa/responsetypes.py index d1b58e53a9..13a0bec3a2 100644 --- a/common/lib/capa/capa/responsetypes.py +++ b/common/lib/capa/capa/responsetypes.py @@ -726,7 +726,7 @@ class NumericalResponse(LoncapaResponse): # I think this is just pyparsing.ParseException, calc.UndefinedVariable: # But we'd need to confirm except: - raise StudentInputError("Invalid input: could not parse '%s' as a number" %\ + raise StudentInputError("Invalid input: could not interpret '%s' as a number" %\ cgi.escape(student_answer)) if correct: @@ -920,6 +920,7 @@ def sympy_check2(): print "oops in customresponse (code) error %s" % err print "context = ", self.context print traceback.format_exc() + raise StudentInputError("Error: Problem could not be evaluated with your input") # Notify student else: # self.code is not a string; assume its a function # this is an interface to the Tutor2 check functions diff --git a/common/lib/xmodule/xmodule/js/src/sequence/display.coffee b/common/lib/xmodule/xmodule/js/src/sequence/display.coffee index ab337d9b7e..25d69ccca3 100644 --- a/common/lib/xmodule/xmodule/js/src/sequence/display.coffee +++ b/common/lib/xmodule/xmodule/js/src/sequence/display.coffee @@ -87,6 +87,8 @@ class @Sequence XModule.loadModules('display', @$('#seq_content')) MathJax.Hub.Queue(["Typeset", MathJax.Hub, "seq_content"]) # NOTE: Actually redundant. Some other MathJax call also being performed + window.update_schematics() # For embedded circuit simulator exercises in 6.002x + @position = new_position @toggleArrows() @hookUpProgressEvent() diff --git a/lms/djangoapps/courseware/module_render.py b/lms/djangoapps/courseware/module_render.py index ee29491d27..b8416426b6 100644 --- a/lms/djangoapps/courseware/module_render.py +++ b/lms/djangoapps/courseware/module_render.py @@ -62,7 +62,7 @@ def toc_for_course(user, request, course, active_chapter, active_section, course where SECTIONS is a list [ {'display_name': name, 'url_name': url_name, - 'format': format, 'due': due, 'active' : bool}, ...] + 'format': format, 'due': due, 'active' : bool, 'graded': bool}, ...] active is set for the section and chapter corresponding to the passed parameters, which are expected to be url_names of the chapter+section. @@ -98,7 +98,9 @@ def toc_for_course(user, request, course, active_chapter, active_section, course 'url_name': section.url_name, 'format': section.metadata.get('format', ''), 'due': section.metadata.get('due', ''), - 'active': active}) + 'active': active, + 'graded': section.metadata.get('graded', False), + }) chapters.append({'display_name': chapter.display_name, 'url_name': chapter.url_name, diff --git a/lms/static/images/graded.png b/lms/static/images/graded.png new file mode 100644 index 0000000000..a1220159f8 Binary files /dev/null and b/lms/static/images/graded.png differ diff --git a/lms/static/sass/course/courseware/_sidebar.scss b/lms/static/sass/course/courseware/_sidebar.scss index 52a639d9a6..27040bece5 100644 --- a/lms/static/sass/course/courseware/_sidebar.scss +++ b/lms/static/sass/course/courseware/_sidebar.scss @@ -180,6 +180,18 @@ section.course-index { font-weight: normal; } } + + &.graded { + > a { + background-image: url('../images/graded.png'); + background-repeat: no-repeat; + background-position: 97% center; + } + + &.active > a { + @include background-image(url('../images/graded.png'), linear-gradient(top, #e6e6e6, #d6d6d6)); + } + } } } } diff --git a/lms/templates/accordion.html b/lms/templates/accordion.html index 0d3dee9495..fa91927462 100644 --- a/lms/templates/accordion.html +++ b/lms/templates/accordion.html @@ -7,7 +7,7 @@