diff --git a/cms/djangoapps/contentstore/views.py b/cms/djangoapps/contentstore/views.py index 3e24655a4a..0f9867c7d2 100644 --- a/cms/djangoapps/contentstore/views.py +++ b/cms/djangoapps/contentstore/views.py @@ -226,6 +226,8 @@ def edit_subsection(request, location): 'create_new_unit_template': Location('i4x', 'edx', 'templates', 'vertical', 'Empty'), 'lms_link': lms_link, 'preview_link': preview_link, + 'course_graders': json.dumps(CourseGradingModel.fetch(course.location).graders), + 'parent_location': course.location, 'parent_item': parent, 'policy_metadata' : policy_metadata, 'subsection_units' : subsection_units, diff --git a/cms/static/js/views/grader-select-view.js b/cms/static/js/views/grader-select-view.js index f810621135..50e32cbbe1 100644 --- a/cms/static/js/views/grader-select-view.js +++ b/cms/static/js/views/grader-select-view.js @@ -35,7 +35,7 @@ CMS.Views.OverviewAssignmentGrader = Backbone.View.extend({ // TODO move to a template file '

<%= assignmentType %>

' + '' + - '' + + '<% if (!hideSymbol) {%><%};%>' + '' + ''); this.assignmentGrade = new CMS.Models.AssignmentGrade({ - assignmentUrl : this.$el.closest('.branch').data('id'), + assignmentUrl : this.$el.closest('.id-holder').data('id'), graderType : this.$el.data('initial-status')}); // TODO throw exception if graders is null this.graders = this.options['graders']; @@ -55,10 +55,12 @@ CMS.Views.OverviewAssignmentGrader = Backbone.View.extend({ cachethis.$el.removeClass('is-active'); $(document).off('click', cachethis.removeMenu); } + this.hideSymbol = this.options['hideSymbol']; this.render(); }, render : function() { - this.$el.html(this.template({ assignmentType : this.assignmentGrade.get('graderType'), graders : this.graders })); + this.$el.html(this.template({ assignmentType : this.assignmentGrade.get('graderType'), graders : this.graders, + hideSymbol : this.hideSymbol })); if (this.assignmentGrade.has('graderType') && this.assignmentGrade.get('graderType') != "Not Graded") { this.$el.addClass('is-set'); } diff --git a/cms/templates/edit_subsection.html b/cms/templates/edit_subsection.html index 6d50842c5b..d3b6f73f13 100644 --- a/cms/templates/edit_subsection.html +++ b/cms/templates/edit_subsection.html @@ -47,7 +47,7 @@