Clean up Manage Groups section on legacy dashboard
This commit is contained in:
@@ -375,29 +375,6 @@ def instructor_dashboard(request, course_id):
|
||||
datatable['data'] = [[s.id, unique_id_for_user(s, save=False), anonymous_id_for_user(s, course_key, save=False)] for s in students]
|
||||
return return_csv(course_key.to_deprecated_string().replace('/', '-') + '-anon-ids.csv', datatable)
|
||||
|
||||
#----------------------------------------
|
||||
# Group management
|
||||
|
||||
elif 'List beta testers' in action:
|
||||
role = CourseBetaTesterRole(course.id)
|
||||
datatable = _role_members_table(role, _("List of Beta Testers"), course_key)
|
||||
track.views.server_track(request, "list-beta-testers", {}, page="idashboard")
|
||||
|
||||
elif action == 'Add beta testers':
|
||||
users = request.POST['betausers']
|
||||
log.debug("users: {0!r}".format(users))
|
||||
role = CourseBetaTesterRole(course.id)
|
||||
for username_or_email in split_by_comma_and_whitespace(users):
|
||||
msg += "<p>{0}</p>".format(
|
||||
add_user_to_role(request, username_or_email, role, 'beta testers', 'beta-tester'))
|
||||
|
||||
elif action == 'Remove beta testers':
|
||||
users = request.POST['betausers']
|
||||
role = CourseBetaTesterRole(course.id)
|
||||
for username_or_email in split_by_comma_and_whitespace(users):
|
||||
msg += "<p>{0}</p>".format(
|
||||
remove_user_from_role(request, username_or_email, role, 'beta testers', 'beta-tester'))
|
||||
|
||||
#----------------------------------------
|
||||
# enrollment
|
||||
|
||||
|
||||
@@ -386,20 +386,7 @@ function goto( mode)
|
||||
|
||||
%if modeflag.get('Manage Groups'):
|
||||
%if instructor_access:
|
||||
<hr width="40%" style="align:left">
|
||||
<p>
|
||||
<input type="submit" name="action" value="List beta testers">
|
||||
<p>
|
||||
## Translators: days_early_for_beta should not be translated
|
||||
${_("Enter usernames or emails for students who should be beta-testers, one per line, or separated by commas. They will get to "
|
||||
"see course materials early, as configured via the <tt>days_early_for_beta</tt> option in the course policy.")}
|
||||
</p>
|
||||
<p>
|
||||
<textarea cols="50" row="30" name="betausers"></textarea>
|
||||
<input type="submit" name="action" value="Remove beta testers">
|
||||
<input type="submit" name="action" value="Add beta testers">
|
||||
</p>
|
||||
<hr width="40%" style="align:left">
|
||||
<p class="deprecated">${_("To manage beta tester roles, please visit the 'Membership' section of the instructor dashboard.")}</p>
|
||||
|
||||
%if course.is_cohorted:
|
||||
<%include file="/course_groups/cohort_management.html" />
|
||||
|
||||
Reference in New Issue
Block a user