Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
9e6249dd
Commit
9e6249dd
authored
Jan 26, 2015
by
cahrens
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enable split for new courses.
parent
61f86369
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
22 deletions
+45
-22
cms/djangoapps/contentstore/views/course.py
+1
-4
cms/envs/common.py
+33
-7
lms/envs/common.py
+11
-11
No files found.
cms/djangoapps/contentstore/views/course.py
View file @
9e6249dd
...
...
@@ -664,10 +664,7 @@ def _create_new_course(request, org, number, run, fields):
Returns the URL for the course overview page.
Raises DuplicateCourseError if the course already exists
"""
store_for_new_course
=
(
settings
.
FEATURES
.
get
(
'DEFAULT_STORE_FOR_NEW_COURSE'
)
or
modulestore
()
.
default_modulestore
.
get_modulestore_type
()
)
store_for_new_course
=
modulestore
()
.
default_modulestore
.
get_modulestore_type
()
new_course
=
create_new_course_in_store
(
store_for_new_course
,
request
.
user
,
org
,
number
,
run
,
fields
)
return
JsonResponse
({
'url'
:
reverse_course_url
(
'course_handler'
,
new_course
.
id
),
...
...
cms/envs/common.py
View file @
9e6249dd
...
...
@@ -35,7 +35,7 @@ import sys
import
lms.envs.common
# Although this module itself may not use these imported variables, other dependent modules may.
from
lms.envs.common
import
(
USE_TZ
,
TECH_SUPPORT_EMAIL
,
PLATFORM_NAME
,
BUGS_EMAIL
,
DOC_STORE_CONFIG
,
ALL_LANGUAGES
,
WIKI_ENABLED
,
MODULESTORE
,
USE_TZ
,
TECH_SUPPORT_EMAIL
,
PLATFORM_NAME
,
BUGS_EMAIL
,
DOC_STORE_CONFIG
,
DATA_DIR
,
ALL_LANGUAGES
,
WIKI_ENABLED
,
update_module_store_settings
,
ASSET_IGNORE_REGEX
,
COPYRIGHT_YEAR
)
from
path
import
path
...
...
@@ -112,9 +112,6 @@ FEATURES = {
# Turn off Advanced Security by default
'ADVANCED_SECURITY'
:
False
,
# Modulestore to use for new courses
'DEFAULT_STORE_FOR_NEW_COURSE'
:
None
,
# Turn off Video Upload Pipeline through Studio, by default
'ENABLE_VIDEO_UPLOAD_PIPELINE'
:
False
,
...
...
@@ -130,9 +127,7 @@ FEATURES = {
'ENABLE_EDXNOTES'
:
False
,
# Enable support for content libraries. Note that content libraries are
# only supported in courses using split mongo. Change the setting
# DEFAULT_STORE_FOR_NEW_COURSE to be 'split' to have future courses
# and libraries created with split.
# only supported in courses using split mongo.
'ENABLE_CONTENT_LIBRARIES'
:
False
,
# Milestones application flag
...
...
@@ -314,6 +309,37 @@ XBLOCK_SELECT_FUNCTION = prefer_xmodules
############################ Modulestore Configuration ################################
MODULESTORE_BRANCH
=
'draft-preferred'
MODULESTORE
=
{
'default'
:
{
'ENGINE'
:
'xmodule.modulestore.mixed.MixedModuleStore'
,
'OPTIONS'
:
{
'mappings'
:
{},
'stores'
:
[
{
'NAME'
:
'split'
,
'ENGINE'
:
'xmodule.modulestore.split_mongo.split_draft.DraftVersioningModuleStore'
,
'DOC_STORE_CONFIG'
:
DOC_STORE_CONFIG
,
'OPTIONS'
:
{
'default_class'
:
'xmodule.hidden_module.HiddenDescriptor'
,
'fs_root'
:
DATA_DIR
,
'render_template'
:
'edxmako.shortcuts.render_to_string'
,
}
},
{
'NAME'
:
'draft'
,
'ENGINE'
:
'xmodule.modulestore.mongo.DraftMongoModuleStore'
,
'DOC_STORE_CONFIG'
:
DOC_STORE_CONFIG
,
'OPTIONS'
:
{
'default_class'
:
'xmodule.hidden_module.HiddenDescriptor'
,
'fs_root'
:
DATA_DIR
,
'render_template'
:
'edxmako.shortcuts.render_to_string'
,
}
}
]
}
}
}
############################ DJANGO_BUILTINS ################################
# Change DEBUG/TEMPLATE_DEBUG in your environment settings files, not here
DEBUG
=
False
...
...
lms/envs/common.py
View file @
9e6249dd
...
...
@@ -627,8 +627,8 @@ MODULESTORE = {
'mappings'
:
{},
'stores'
:
[
{
'NAME'
:
'
draf
t'
,
'ENGINE'
:
'xmodule.modulestore.
mongo.DraftMongo
ModuleStore'
,
'NAME'
:
'
spli
t'
,
'ENGINE'
:
'xmodule.modulestore.
split_mongo.split_draft.DraftVersioning
ModuleStore'
,
'DOC_STORE_CONFIG'
:
DOC_STORE_CONFIG
,
'OPTIONS'
:
{
'default_class'
:
'xmodule.hidden_module.HiddenDescriptor'
,
...
...
@@ -637,23 +637,23 @@ MODULESTORE = {
}
},
{
'NAME'
:
'xml'
,
'ENGINE'
:
'xmodule.modulestore.xml.XMLModuleStore'
,
'NAME'
:
'draft'
,
'ENGINE'
:
'xmodule.modulestore.mongo.DraftMongoModuleStore'
,
'DOC_STORE_CONFIG'
:
DOC_STORE_CONFIG
,
'OPTIONS'
:
{
'data_dir'
:
DATA_DIR
,
'default_class'
:
'xmodule.hidden_module.HiddenDescriptor'
,
'fs_root'
:
DATA_DIR
,
'render_template'
:
'edxmako.shortcuts.render_to_string'
,
}
},
{
'NAME'
:
'split'
,
'ENGINE'
:
'xmodule.modulestore.split_mongo.split_draft.DraftVersioningModuleStore'
,
'DOC_STORE_CONFIG'
:
DOC_STORE_CONFIG
,
'NAME'
:
'xml'
,
'ENGINE'
:
'xmodule.modulestore.xml.XMLModuleStore'
,
'OPTIONS'
:
{
'data_dir'
:
DATA_DIR
,
'default_class'
:
'xmodule.hidden_module.HiddenDescriptor'
,
'fs_root'
:
DATA_DIR
,
'render_template'
:
'edxmako.shortcuts.render_to_string'
,
}
}
,
}
]
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment