From 5d7f820d93d88b53da514709d3b6b212a96511fe Mon Sep 17 00:00:00 2001 From: Sarina Canelake Date: Wed, 13 Aug 2014 15:58:27 -0400 Subject: [PATCH] Clean up Admin section of legacy dashboard --- lms/djangoapps/instructor/views/legacy.py | 33 ------------------- .../legacy_instructor_dashboard.html | 17 ++-------- 2 files changed, 2 insertions(+), 48 deletions(-) diff --git a/lms/djangoapps/instructor/views/legacy.py b/lms/djangoapps/instructor/views/legacy.py index c5a1122d39..42dc3ef6f3 100644 --- a/lms/djangoapps/instructor/views/legacy.py +++ b/lms/djangoapps/instructor/views/legacy.py @@ -313,39 +313,6 @@ def instructor_dashboard(request, course_id): msg2, __ = _do_remote_gradebook(request.user, course, 'post-grades', files=files) msg += msg2 - #---------------------------------------- - # Admin - - elif 'List course staff' in action: - role = CourseStaffRole(course.id) - datatable = _role_members_table(role, _("List of Staff"), course_key) - track.views.server_track(request, "list-staff", {}, page="idashboard") - - elif 'List course instructors' in action and GlobalStaff().has_user(request.user): - role = CourseInstructorRole(course.id) - datatable = _role_members_table(role, _("List of Instructors"), course_key) - track.views.server_track(request, "list-instructors", {}, page="idashboard") - - elif action == 'Add course staff': - uname = request.POST['staffuser'] - role = CourseStaffRole(course.id) - msg += add_user_to_role(request, uname, role, 'staff', 'staff') - - elif action == 'Add instructor' and request.user.is_staff: - uname = request.POST['instructor'] - role = CourseInstructorRole(course.id) - msg += add_user_to_role(request, uname, role, 'instructor', 'instructor') - - elif action == 'Remove course staff': - uname = request.POST['staffuser'] - role = CourseStaffRole(course.id) - msg += remove_user_from_role(request, uname, role, 'staff', 'staff') - - elif action == 'Remove instructor' and request.user.is_staff: - uname = request.POST['instructor'] - role = CourseInstructorRole(course.id) - msg += remove_user_from_role(request, uname, role, 'instructor', 'instructor') - #---------------------------------------- # DataDump diff --git a/lms/templates/courseware/legacy_instructor_dashboard.html b/lms/templates/courseware/legacy_instructor_dashboard.html index 80f17164fe..325bab5dee 100644 --- a/lms/templates/courseware/legacy_instructor_dashboard.html +++ b/lms/templates/courseware/legacy_instructor_dashboard.html @@ -298,24 +298,11 @@ function goto( mode) %if modeflag.get('Admin'): %if instructor_access: -
-

- -

- - - -


+

${_("To add or remove course staff, please visit the 'Membership' section of the instructor dashboard.")}

%endif %if admin_access: -
-

- -

- - -


+

${_("To add or remove course instructors, please visit the 'Membership' section of the instructor dashboard.")}

%endif %if settings.FEATURES['ENABLE_MANUAL_GIT_RELOAD'] and admin_access: