From dbbbe8f2cb00b3113be4db847eb09e2cea064cbf Mon Sep 17 00:00:00 2001
From: Braden MacDonald
Date: Tue, 19 Aug 2014 21:30:21 -0700
Subject: [PATCH] Fix: inadvertent scroll when loading the instructor's
extensions tab
(The div with id "view-extensions" conflicts with the tab JS which sets location.hash to "view-x" in order to track the current tab)
---
.../coffee/src/instructor_dashboard/extensions.coffee | 8 ++++----
.../instructor/instructor_dashboard_2/extensions.html | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/lms/static/coffee/src/instructor_dashboard/extensions.coffee b/lms/static/coffee/src/instructor_dashboard/extensions.coffee
index acfcf7d363..d3c6a66ab7 100644
--- a/lms/static/coffee/src/instructor_dashboard/extensions.coffee
+++ b/lms/static/coffee/src/instructor_dashboard/extensions.coffee
@@ -70,7 +70,7 @@ class Extensions
@clear_display()
@$grid_table.text 'Loading...'
- @$url_input = @$section.find("#view-extensions select[name='url']")
+ @$url_input = @$section.find("#view-granted-extensions select[name='url']")
url = @$show_unit_extensions.data 'endpoint'
send_data =
url: @$url_input.val()
@@ -78,7 +78,7 @@ class Extensions
dataType: 'json'
url: url
data: send_data
- error: (xhr) => @fail_with_error "view-extensions", "Error getting due dates", xhr
+ error: (xhr) => @fail_with_error "view-granted-extensions", "Error getting due dates", xhr
success: (data) => @display_grid data
@$show_student_extensions.click =>
@@ -86,14 +86,14 @@ class Extensions
@$grid_table.text 'Loading...'
url = @$show_student_extensions.data 'endpoint'
- @$student_input = @$section.find("#view-extensions input[name='student']")
+ @$student_input = @$section.find("#view-granted-extensions input[name='student']")
send_data =
student: @$student_input.val()
$.ajax
dataType: 'json'
url: url
data: send_data
- error: (xhr) => @fail_with_error "view-extensions", "Error getting due dates", xhr
+ error: (xhr) => @fail_with_error "view-granted-extensions", "Error getting due dates", xhr
success: (data) => @display_grid data
# handler for when the section title is clicked.
diff --git a/lms/templates/instructor/instructor_dashboard_2/extensions.html b/lms/templates/instructor/instructor_dashboard_2/extensions.html
index 3b11f5eea9..4405f89e30 100644
--- a/lms/templates/instructor/instructor_dashboard_2/extensions.html
+++ b/lms/templates/instructor/instructor_dashboard_2/extensions.html
@@ -39,7 +39,7 @@
-
+
${_("Viewing granted extensions")}
${_("Here you can see what extensions have been granted on particular "