show button new library in studio depending on flags and user staff status

add flag DISABLE_LIBRARY_CREATION

add comma

use CourseCreatorRole to determine if user can create a library

add disable library creation feature flag

Conflicts:
	cms/djangoapps/contentstore/views/course.py

ENABLE_CONTENT_LIBRARIES flag

check for course creator role for library creation

Conflicts:
	cms/djangoapps/contentstore/views/course.py

add unit tests

make check of creation of library a true/false for forntend, add security in api call, clean tests

update tests

fix docstring of tests

fixed quality violation

fixed broken unit test and quality violations

Feedback changes and unit test to assert libraries are visible to non staff users too

fixed quality violation and feedback changes
This commit is contained in:
jagonzalr
2016-11-03 14:59:39 +02:00
committed by Zia Fazal
parent 2adb03ec8d
commit d112c0b81b
6 changed files with 120 additions and 26 deletions

View File

@@ -33,7 +33,6 @@ from openedx.core.djangolib.markup import HTML, Text
% elif course_creator_status=='disallowed_for_this_site' and settings.FEATURES.get('STUDIO_REQUEST_EMAIL',''):
<a href="mailto:${settings.FEATURES.get('STUDIO_REQUEST_EMAIL','')}">${_("Email staff to create course")}</a>
% endif
% if show_new_library_button:
<a href="#" class="button new-button new-library-button"><span class="icon fa fa-plus icon-inline" aria-hidden="true"></span>
${_("New Library")}</a>