Merge pull request #18601 from edx/mroytman/enabled-launch-checklist-for-all

enable course launch checklist for all staff
This commit is contained in:
Michael Roytman
2018-07-18 11:54:26 -04:00
committed by GitHub
3 changed files with 4 additions and 6 deletions

View File

@@ -4,15 +4,13 @@ from cms.djangoapps.contentstore.config.waffle import waffle, ENABLE_CHECKLISTS_
from student.roles import GlobalStaff
def should_show_checklists_page(requesting_user):
def should_show_checklists_page():
"""
Determine if the ENABLE_CHECKLISTS_PAGE waffle switch is set
and if the user is able to see it
"""
if waffle().is_enabled(ENABLE_CHECKLISTS_PAGE):
if GlobalStaff().has_user(requesting_user):
return True
return True
return False

View File

@@ -180,7 +180,7 @@ from openedx.core.djangolib.markup import HTML, Text
% endif
</div>
<div class="status-highlights-enabled"></div>
% if should_show_checklists_page(request.user):
% if should_show_checklists_page():
<div class="status-checklist">
<%static:studiofrontend entry="courseOutlineHealthCheck">
{

View File

@@ -127,7 +127,7 @@
<a href="${reverse('export_git', kwargs=dict(course_key_string=unicode(course_key)))}">${_("Export to Git")}</a>
</li>
% endif
% if should_show_checklists_page(request.user):
% if should_show_checklists_page():
<li class="nav-item nav-course-tools-checklists">
<a href="${checklists_url}">${_("Checklists")}</a>
</li>