diff --git a/cms/djangoapps/contentstore/views.py b/cms/djangoapps/contentstore/views.py index 153e37ed82..caf3901e03 100644 --- a/cms/djangoapps/contentstore/views.py +++ b/cms/djangoapps/contentstore/views.py @@ -1487,6 +1487,12 @@ def create_new_course(request): new_course = modulestore('direct').clone_item(template, dest_location) + # clone a default 'about' module as well + + about_template_location = Location(['i4x', 'edx', 'templates', 'about', 'overview']) + dest_about_location = dest_location._replace(category='about', name='overview') + modulestore('direct').clone_item(about_template_location, dest_about_location) + if display_name is not None: new_course.display_name = display_name diff --git a/cms/templates/settings.html b/cms/templates/settings.html index 3923c0f905..0a647c632e 100644 --- a/cms/templates/settings.html +++ b/cms/templates/settings.html @@ -179,7 +179,7 @@ from contentstore import utils
  • - Introductions, prerequisites, FAQs that are used on your course summary page + Introductions, prerequisites, FAQs that are used on your course summary page (formatted in HTML)
  • diff --git a/common/lib/xmodule/xmodule/modulestore/store_utilities.py b/common/lib/xmodule/xmodule/modulestore/store_utilities.py index e90613d0da..6beffcb71d 100644 --- a/common/lib/xmodule/xmodule/modulestore/store_utilities.py +++ b/common/lib/xmodule/xmodule/modulestore/store_utilities.py @@ -13,10 +13,19 @@ def clone_course(modulestore, contentstore, source_location, dest_location, dele if not modulestore.has_item(dest_location): raise Exception("An empty course at {0} must have already been created. Aborting...".format(dest_location)) - # verify that the dest_location really is an empty course, which means only one + # verify that the dest_location really is an empty course, which means only one with an optional 'overview' dest_modules = modulestore.get_items([dest_location.tag, dest_location.org, dest_location.course, None, None, None]) - if len(dest_modules) != 1: + basically_empty = True + for module in dest_modules: + if module.location.category == 'course' or (module.location.category == 'about' + and module.location.name == 'overview'): + continue + + basically_empty = False + break + + if not basically_empty: raise Exception("Course at destination {0} is not an empty course. You can only clone into an empty course. Aborting...".format(dest_location)) # check to see if the source course is actually there diff --git a/common/lib/xmodule/xmodule/templates/about/overview.yaml b/common/lib/xmodule/xmodule/templates/about/overview.yaml new file mode 100644 index 0000000000..0031ebffaf --- /dev/null +++ b/common/lib/xmodule/xmodule/templates/about/overview.yaml @@ -0,0 +1,53 @@ +--- +metadata: + display_name: overview + +data: | +
    +

    About This Course

    +

    Include your long course description here. The long course description should contain 150-400 words.

    + +

    This is paragraph 2 of the long course description. Add more paragraphs as needed. Make sure to enclose them in paragraph tags.

    +
    + +
    +

    Prerequisites

    +

    Add information about course prerequisites here.

    +
    + +
    +

    Course Staff

    +
    +
    + +
    + +

    Staff Member #1

    +

    Biography of instructor/staff member #1

    +
    + +
    +
    + +
    + +

    Staff Member #2

    +

    Biography of instructor/staff member #2

    +
    +
    + +
    +
    +

    Frequently Asked Questions

    +
    +

    Do I need to buy a textbook?

    +

    No, a free online version of Chemistry: Principles, Patterns, and Applications, First Edition by Bruce Averill and Patricia Eldredge will be available, though you can purchase a printed version (published by FlatWorld Knowledge) if you’d like.

    +
    + +
    +

    Question #2

    +

    Your answer would be displayed here.

    +
    +
    +
    +children: [] diff --git a/common/static/images/pl-course.png b/common/static/images/pl-course.png new file mode 100644 index 0000000000..1a3da9e631 Binary files /dev/null and b/common/static/images/pl-course.png differ diff --git a/common/static/images/pl-faculty.png b/common/static/images/pl-faculty.png new file mode 100644 index 0000000000..b55ba44542 Binary files /dev/null and b/common/static/images/pl-faculty.png differ diff --git a/lms/static/sass/multicourse/_course_about.scss b/lms/static/sass/multicourse/_course_about.scss index d23917fe27..0982577f42 100644 --- a/lms/static/sass/multicourse/_course_about.scss +++ b/lms/static/sass/multicourse/_course_about.scss @@ -272,7 +272,9 @@ } .course-staff { + .teacher { + @include clearfix; margin-bottom: 40px; h3 { @@ -312,7 +314,7 @@ } } } - + .faq { @include clearfix;