Commit 54156b7a by cahrens

Saving work.

parent bf71f099
......@@ -113,9 +113,6 @@ def howitworks(request):
else:
return render_to_response('howitworks.html', {})
def ux_checklists(request):
return render_to_response('ux-checklists.html', {})
# ==== Views for any logged-in user ==================================
......@@ -179,11 +176,7 @@ def course_index(request, org, course, name):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
lms_link = get_lms_link_for_item(location)
......@@ -1071,11 +1064,7 @@ def course_info(request, org, course, name, provided_id=None):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
course_module = modulestore().get_item(location)
......@@ -1170,11 +1159,7 @@ def get_course_settings(request, org, course, name):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
course_module = modulestore().get_item(location)
......@@ -1197,11 +1182,7 @@ def course_config_graders_page(request, org, course, name):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
course_module = modulestore().get_item(location)
course_details = CourseGradingModel.fetch(location)
......@@ -1221,11 +1202,7 @@ def course_config_advanced_page(request, org, course, name):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
course_module = modulestore().get_item(location)
......@@ -1280,11 +1257,7 @@ def course_grader_updates(request, org, course, name, grader_index=None):
org, course: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
if request.method == 'POST' and 'HTTP_X_HTTP_METHOD_OVERRIDE' in request.META:
real_method = request.META['HTTP_X_HTTP_METHOD_OVERRIDE']
......@@ -1314,11 +1287,7 @@ def course_advanced_updates(request, org, course, name):
org, course: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
# NB: we're setting Backbone.emulateHTTP to true on the client so everything comes as a post!!!
if request.method == 'POST' and 'HTTP_X_HTTP_METHOD_OVERRIDE' in request.META:
......@@ -1335,6 +1304,27 @@ def course_advanced_updates(request, org, course, name):
return HttpResponse(json.dumps(CourseMetadata.update_from_json(location, json.loads(request.body))), mimetype="application/json")
#@ensure_csrf_cookie what is this cookie?
@login_required
def get_checklists(request, org, course, name):
location = get_location_and_verify_access(request, org, course, name)
modulestore = get_modulestore(location)
course_module = modulestore.get_item(location)
new_course_template = Location('i4x', 'edx', 'templates', 'course', 'Empty')
template_module = modulestore.get_item(new_course_template)
# If course was created before checklists were introduced, copy them over from the template.
key = "checklists"
if not key in course_module.metadata:
course_module.metadata[key] = template_module.metadata[key]
modulestore.update_metadata(location, course_module.metadata)
return render_to_response('checklists.html',
{'checklists' : course_module.metadata[key]})
@login_required
@ensure_csrf_cookie
def asset_index(request, org, course, name):
......@@ -1343,12 +1333,7 @@ def asset_index(request, org, course, name):
org, course, name: Attributes of the Location for the item to edit
"""
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
upload_asset_callback_url = reverse('upload_asset', kwargs={
'org': org,
......@@ -1473,11 +1458,7 @@ def initialize_course_tabs(course):
@login_required
def import_course(request, org, course, name):
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
if request.method == 'POST':
filename = request.FILES['course-data'].name
......@@ -1550,10 +1531,7 @@ def import_course(request, org, course, name):
@ensure_csrf_cookie
@login_required
def generate_export_course(request, org, course, name):
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
location = get_location_and_verify_access(request, org, course, name)
loc = Location(location)
export_file = NamedTemporaryFile(prefix=name + '.', suffix=".tar.gz")
......@@ -1586,11 +1564,9 @@ def generate_export_course(request, org, course, name):
@login_required
def export_course(request, org, course, name):
location = ['i4x', org, course, 'course', name]
location = get_location_and_verify_access(request, org, course, name)
course_module = modulestore().get_item(location)
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
return render_to_response('export.html', {
'context_course': course_module,
......@@ -1605,3 +1581,12 @@ def event(request):
console logs don't get distracted :-)
'''
return HttpResponse(True)
def get_location_and_verify_access(request, org, course, name):
location = ['i4x', org, course, 'course', name]
# check that logged in user has permissions to this item
if not has_access(request.user, location):
raise PermissionDenied()
return location
\ No newline at end of file
CMS.Views.Checklists = Backbone.View.extend({
// takes CMS.Models.CourseInfo as model
tagName: 'div',
render: function() {
// instantiate the ClassInfoUpdateView and delegate the proper dom to it
new CMS.Views.ClassInfoUpdateView({
el: $('body.updates'),
collection: this.model.get('updates')
});
new CMS.Views.ClassInfoHandoutsView({
el: this.$('#course-handouts-view'),
model: this.model.get('handouts')
});
return this;
}
});
\ No newline at end of file
<%inherit file="base.html" />
<%block name="title">Course Checklists</%block>
<%block name="bodyclass">is-signedin course checklists</%block>
<%block name="jsextra">
<script type="text/javascript">
// checklists - prototype/basic concept JS
$(document).ready(function() {
});
</script>
</%block>
<%block name="bodyclass">is-signedin course uxdesign checklists</%block>
<%block name="content">
<div class="wrapper-mast wrapper">
<header class="mast has-actions has-subtitle">
<div class="title">
<span class="title-sub">UX Design</span>
<h1 class="title-1">Alerts &amp; Notifications</h1>
</div>
</header>
<header class="mast has-actions has-subtitle">
<div class="title">
<span class="title-sub">Tools</span>
<h1 class="title-1">Course Tasks &amp; Checklists</h1>
</div>
</header>
</div>
<div class="wrapper-content wrapper">
<section class="content">
<article class="content-primary" role="main">
<section>
<header>
<h2 class="title-2">Alerts</h2>
<span class="tip">persistant, static messages to the user</span>
</header>
<p>In Studio, alerts are 1) general warnings/notes (e.g. drafts, published content, next steps) about the current view a user is interacting with or 2) notes about the status (e.g. saved confirmations, errors, next system steps) of any previous state that need to communicated to the user when arriving at the current view.</p>
</section>
</article>
</section>
<section class="content">
<article class="content-primary" role="main">
<form id="course-checklists" class="course-checklists" method="post" action="">
<h2 class="title title-3 sr">Current Checklists</h2>
% for checklist in checklists:
<section class="course-checklist" id=${'course-checklist' + str(loop.index)}>
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i>${checklist['short_description']}</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">0</span>/<span class="status-amount">4</span></span>
</header>
<ul class="list list-tasks">
% for item in checklist['items']:
<li class="task">
<label for=${'course-checklist' + str(loop.parent.index) + '-task' + str(loop.index)}>
<input type="checkbox" class="task-input" name=${'course-checklist' + str(loop.parent.index) + '-task' + str(loop.index)}
id=${'course-checklist' + str(loop.parent.index) + '-task' + str(loop.index)}
value=${item['is_checked']}>
<div class="task-details">
<h4 class="task-name title title-3">${item['short_description']}</h4>
<p class="task-description">${item['long_description']}</p>
</div>
</label>
% if item['action_text'] is not '' and item['action_url'] is not '':
<ul class="list-actions task-actions">
<li>
<a href=${item['action_url']} class="action action-primary">${item['action_text']}</a>
</li>
</ul>
% endif
</li>
% endfor
</ul>
</section>
% endfor
<section class="course-checklist" id="course-checklist1">
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i> Getting Started with Studio</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">0</span>/<span class="status-amount">4</span></span>
</header>
<ul class="list list-tasks">
<li class="task">
<label for="course-checklist1-task1">
<input type="checkbox" class="task-input" name="course-checklist1-task1" id="course-checklist1-task1" value="course-checklist1-task1 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course Team Members</h4>
<p class="task-description">Grant your collaborators permission to edit your course so you can work together.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit Team Members</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist1-task2">
<input type="checkbox" class="task-input" name="course-checklist1-task2" id="course-checklist1-task2" value="course-checklist1-task2 complete">
<div class="task-details">
<h4 class="task-name title title-3">Set Your Course's Important Dates</h4>
<p class="task-description">Donec sed odio dui. Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Edit Course Schedule &amp; Details </a>
</li>
</ul>
</li>
<li class="task is-not-available">
<label for="course-checklist1-task3">
<input type="checkbox" class="task-input" name="course-checklist1-task3" id="course-checklist1-task3" value="course-checklist1-task3 complete">
<div class="task-details">
<h4 class="task-name title title-3">Draft Your Course's Grading Policy</h4>
<p class="task-description">Regardless of whether you have all your course assignments written, you can immediately get started setting up assignment types and a grade computation scheme.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit Grading Settings</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist1-task4">
<input type="checkbox" class="task-input" name="course-checklist1-task4" id="course-checklist1-task4" value="course-checklist1-task4 complete">
<div class="task-details">
<h4 class="task-name title title-3">Explore the other Studio Checklists</h4>
<p class="task-description">They'll help you learn the other course authoring tools available to you, and will also help you find help when you need it.</p>
</div>
</label>
</li>
</ul>
<ul class="list-actions course-checklist-actions">
<h5 class="sr">Edit This Checklist</h5>
<li>
<a href="#" class="action action-primary"><i class="ss-icon ss-symbolicons-standard icon-add">&#x002B;</i> Add a Task <span class="sr">to This Checklist</span></a>
</li>
<li>
<a href="#" class="action action-secondary action-delete"><i class="ss-icon ss-symbolicons-block icon-delete">&#xE0D0;</i> Delete This Checklist</a>
</li>
</ul>
</section>
<section class="course-checklist" id="course-checklist2">
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i> Draft a Rough Course Outline</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">0</span>/<span class="status-amount">7</span></span>
</header>
<ul class="list list-tasks">
<li class="task">
<label for="course-checklist2-task1">
<input type="checkbox" class="task-input" name="course-checklist2-task1" id="course-checklist2-task1" value="course-checklist2-task1 complete">
<div class="task-details">
<h4 class="task-name title title-3">Create your first Section and Subsection</h4>
<p class="task-description">Walk through the mechanics of building your course's first section and subsection through your course outline to start.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist2-task2">
<input type="checkbox" class="task-input" name="course-checklist2-task2" id="course-checklist2-task2" value="course-checklist2-task2 complete">
<div class="task-details">
<h4 class="task-name title title-3">Set your 1st Section's Release Date</h4>
<p class="task-description">Sections are released sequentially to students, and you have complete control over they are released to students.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task is-not-available">
<label for="course-checklist2-task3">
<input type="checkbox" class="task-input" name="course-checklist2-task3" id="course-checklist2-task3" value="course-checklist2-task3 complete">
<div class="task-details">
<h4 class="task-name title title-3">Designate a Subsection as Graded</h4>
<p class="task-description">Assignment types are defined in your grading settings but can be quickly associated with sections using your course outline.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist2-task4">
<input type="checkbox" class="task-input" name="course-checklist2-task4" id="course-checklist2-task4" value="course-checklist2-task4 complete">
<div class="task-details">
<h4 class="task-name title title-3">Reordering Course Content</h4>
<p class="task-description">From the Course Outline, you can easily reorder your course content based on the progression you'd like students to walk through.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist2-task5">
<input type="checkbox" class="task-input" name="course-checklist2-task5" id="course-checklist2-task5" value="course-checklist2-task5 complete">
<div class="task-details">
<h4 class="task-name title title-3">Renaming Course Sections</h4>
<p class="task-description">Learn how to rename Sections by clicking on its name from the Course Outline; this should open the editing mode.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist2-task6">
<input type="checkbox" class="task-input" name="course-checklist2-task6" id="course-checklist2-task6" value="course-checklist2-task6 complete">
<div class="task-details">
<h4 class="task-name title title-3">Deleting Course Content</h4>
<p class="task-description">Try out deleting on a section, subsection, or unit you don't need anymore. Be careful though, anything inside the course content you delete is also removed.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist2-task7">
<input type="checkbox" class="task-input" name="course-checklist2-task7" id="course-checklist2-task7" value="course-checklist2-task7 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add an Instructor-Only Section to Your Outline</h4>
<p class="task-description">Some course authors find creating a section for unsorted, in-progress work useful. To do this, create a section and set the release date to the distant future.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit in Course Outline</a>
</li>
</ul>
</li>
</ul>
<ul class="list-actions course-checklist-actions">
<h5 class="sr">Edit This Checklist</h5>
<li>
<a href="#" class="action action-primary"><i class="ss-icon ss-symbolicons-standard icon-add">&#x002B;</i> Add a Task <span class="sr">to This Checklist</span></a>
</li>
<li>
<a href="#" class="action action-secondary action-delete"><i class="ss-icon ss-symbolicons-block icon-delete">&#xE0D0;</i> Delete This Checklist</a>
</li>
</ul>
</section>
<section class="course-checklist" id="course-checklist3">
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i> Explore edX's Support Tools</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">0</span>/<span class="status-amount">4</span></span>
</header>
<ul class="list list-tasks">
<li class="task">
<label for="course-checklist3-task1">
<input type="checkbox" class="task-input" name="course-checklist3-task1" id="course-checklist3-task1" value="course-checklist3-task1 complete">
<div class="task-details">
<h4 class="task-name title title-3">Explore the Studio Help Forum</h4>
<p class="task-description">Access the Studio Help forum from the menu that appears when you click your user name in the top right corner of Studio.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Visit edX Studio Help</a>
</li>
</ul>
</li>
<li class="task is-completed">
<label for="course-checklist3-task2">
<input type="checkbox" class="task-input" name="course-checklist3-task2" id="course-checklist3-task2" value="course-checklist3-task2 complete">
<div class="task-details">
<h4 class="task-name title title-3">Enroll in edX101</h4>
<p class="task-description">Register for edX101, edX's primer for course creation.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Register for edX101</a>
</li>
</ul>
</li>
<li class="task is-not-available">
<label for="course-checklist3-task3">
<input type="checkbox" class="task-input" name="course-checklist3-task3" id="course-checklist3-task3" value="course-checklist3-task3 complete">
<div class="task-details">
<h4 class="task-name title title-3">Download the Studio Documentation</h4>
<p class="task-description">View the searchable Studio documentation to find answers to your questions or information about how to do specific tasks. Once you download the PDF, you can view it offline.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Download Documentation</a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist3-task4">
<input type="checkbox" class="task-input" name="course-checklist3-task4" id="course-checklist3-task4" value="course-checklist3-task4 complete">
<div class="task-details">
<h4 class="task-name title title-3">Explore the other Studio Checklists</h4>
<p class="task-description">They'll help you learn the other course authoring tools available to you, and will also help you find help when you need it.</p>
</div>
</label>
</li>
</ul>
<ul class="list-actions course-checklist-actions">
<h5 class="sr">Edit This Checklist</h5>
<li>
<a href="#" class="action action-primary"><i class="ss-icon ss-symbolicons-standard icon-add">&#x002B;</i> Add a Task <span class="sr">to This Checklist</span></a>
</li>
<li>
<a href="#" class="action action-secondary action-delete"><i class="ss-icon ss-symbolicons-block icon-delete">&#xE0D0;</i> Delete This Checklist</a>
</li>
</ul>
</section>
<section class="course-checklist" id="course-checklist4">
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i> Draft your Course Introduction</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">0</span>/<span class="status-amount">4</span></span>
</header>
<ul class="list list-tasks">
<li class="task">
<label for="course-checklist4-task1">
<input type="checkbox" class="task-input" name="course-checklist4-task1" id="course-checklist4-task1" value="course-checklist4-task1 complete">
<div class="task-details">
<h4 class="task-name title title-3">Drafting a Course Description/h4>
<p class="task-description">Courses on edX each have their own introduction page, including a course video, description, and more. Draft the introduction students will read before deciding to enroll in your course.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Edit Course Schedule &amp; Details </a>
</li>
</ul>
</li>
<li class="task is-completed">
<label for="course-checklist4-task2">
<input type="checkbox" class="task-input" name="course-checklist4-task2" id="course-checklist4-task2" value="course-checklist4-task2 complete">
<div class="task-details">
<h4 class="task-name title title-3">Adding Staff Bios</h4>
<p class="task-description">Showing prospective students who will be their instructor is helpful, so we recommend including staff bios in the Course introduction page.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Edit Course Schedule &amp; Details </a>
</li>
</ul>
</li>
<li class="task is-not-available">
<label for="course-checklist4-task3">
<input type="checkbox" class="task-input" name="course-checklist4-task3" id="course-checklist4-task3" value="course-checklist4-task3 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course FAQs</h4>
<p class="task-description">Students often have questions about courses, and including a short list of frequently asked questions up front often reduces the number of students who are confused.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Edit Course Schedule &amp; Details </a>
</li>
</ul>
</li>
<li class="task">
<label for="course-checklist4-task4">
<input type="checkbox" class="task-input" name="course-checklist4-task4" id="course-checklist4-task4" value="course-checklist4-task4 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course Prerequisites</h4>
<p class="task-description">Before a student jumps into a course without the necessary preparation, we'd like them to understand the prerequisites that will make them more likely to succeed.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary link-pdf">Edit Course Schedule &amp; Details </a>
</li>
</ul>
</li>
</ul>
<ul class="list-actions course-checklist-actions">
<h5 class="sr">Edit This Checklist</h5>
<li>
<a href="#" class="action action-primary"><i class="ss-icon ss-symbolicons-standard icon-add">&#x002B;</i> Add a Task <span class="sr">to This Checklist</span></a>
</li>
<li>
<a href="#" class="action action-secondary action-delete"><i class="ss-icon ss-symbolicons-block icon-delete">&#xE0D0;</i> Delete This Checklist</a>
</li>
</ul>
</section>
<hr class="divider" />
<h2 class="title title-3 sr">Completed Checklists</h2>
<section class="course-checklist is-completed" id="course-checklist5">
<header>
<h3 class="checklist-title title-2"><i class="ss-icon ss-symbolicons-standard icon-confirm">&#x2713;</i> Completed Checklist Example</h3>
<span class="checklist-status status">Tasks Completed: <span class="status-count">3</span>/<span class="status-amount">3</span></span>
</header>
<ul class="list list-tasks">
<li class="task is-completed">
<label for="course-checklist5-task1">
<input checked type="checkbox" class="task-input" name="course-checklist5-task1" id="course-checklist5-task1" value="course-checklist5-task1 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course Team Members</h4>
<p class="task-description">Grant your collaborators permission to edit your course so you can work together.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit Team Members</a>
</li>
</ul>
</li>
<li class="task is-completed">
<label for="course-checklist5-task2">
<input checked type="checkbox" class="task-input" name="course-checklist5-task2" id="course-checklist5-task2" value="course-checklist5-task2 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course Team Members</h4>
<p class="task-description">Grant your collaborators permission to edit your course so you can work together.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit Team Members</a>
</li>
</ul>
</li>
<li class="task is-completed">
<label for="course-checklist5-task3">
<input checked type="checkbox" class="task-input" name="course-checklist5-task3" id="course-checklist5-task3" value="course-checklist5-task3 complete">
<div class="task-details">
<h4 class="task-name title title-3">Add Course Team Members</h4>
<p class="task-description">Grant your collaborators permission to edit your course so you can work together. Grant your collaborators permission to edit your course so you can work together. Grant your collaborators permission to edit your course so you can work together. Grant your collaborators permission to edit your course so you can work together.</p>
</div>
</label>
<ul class="list-actions task-actions">
<li>
<a href="#" class="action action-primary">Edit Team Members</a>
</li>
</ul>
</li>
</ul>
<ul class="list-actions course-checklist-actions">
<h5 class="sr">Edit This Checklist</h5>
<li>
<a href="#" class="action action-primary"><i class="ss-icon ss-symbolicons-standard icon-add">&#x002B;</i> Add a Task <span class="sr">to This Checklist</span></a>
</li>
<li>
<a href="#" class="action action-secondary action-delete"><i class="ss-icon ss-symbolicons-block icon-delete">&#xE0D0;</i> Delete This Checklist</a>
</li>
</ul>
</section>
<hr class="divider" />
</form>
</article>
<aside class="content-supplementary" role="complimentary">
<div class="bit">
<h3 class="title title-3">What are Checklists?</h3>
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium.</p>
</div>
<div class="bit">
<h3 class="title title-3">Current Checklists</h3>
<nav class="nav-page checklists-current">
<ol>
<li class="nav-item">
<a href="#course-checklist1">Getting Started with Studio</a>
</li>
<li class="nav-item">
<a href="#course-checklist2">Draft a Rough Course Outline</a>
</li>
<li class="nav-item">
<a href="#course-checklist3">Explore edX's Support Tools</a>
</li>
<li class="nav-item">
<a href="#course-checklist4">Draft your Course Introduction</a>
</li>
</ol>
</nav>
</div>
<div class="bit">
<h3 class="title title-3">Completed Checklists</h3>
<nav class="nav-page checklists-completed">
<ol>
<li class="nav-item">
<a href="#course-checklist1">Getting Started with Studio</a>
</li>
</ol>
</nav>
</div>
</aside>
</section>
</div>
</%block>
<%block name="view_alerts">
<!-- alerts, notifications, prompts here -->
<!-- alert: save confirmed with close -->
<div class="wrapper wrapper-alert wrapper-alert-confirmation">
<div class="alert confirmation">
<i class="ss-icon ss-symbolicons-standard icon icon-confirmation">&#x2713;</i>
<div class="copy">
<h2 class="title title-3">Your policy changes have been saved.</h2>
<p>Please note that validation of your policy key and value pairs is not currently in place yet. If you are having difficulties, please review your policy pairs.</p>
</div>
<a href="#" rel="view" class="action action-alert-close">
<i class="ss-icon ss-symbolicons-block icon icon-close">&#x2421;</i>
<span class="label">close alert</span>
</a>
</div>
</div>
</%block>
<%block name="jsextra">
<script type="text/javascript">
// checklists - prototype/basic js
$(document).ready(function() {
$('.course-checklist .checklist-title').each(function(e){
$(this).addClass('is-selectable').attr('title','Collapse/Expand this Checklist').bind('click', toggleChecklist);
});
$('.course-checklist .task label').each(function(e){
$(this).bind('click', toggleTask);
});
function toggleChecklist(e) {
(e).preventDefault();
$(this).closest('.course-checklist').toggleClass('is-collapsed');
}
function toggleTask(e) {
(e).preventDefault();
var $taskInput = $(this).find('.task-input');
if ($taskInput.attr('checked')) {
$taskInput.removeAttr('checked');
console.log('removing check');
}
else {
$taskInput.attr('checked', 'checked');
console.log('adding check');
}
$(this).closest('.task').toggleClass('is-completed');
}
// in-progress update checklist progress (based on checkbox check/uncheck events)
function updateChecklistProgress() {
var $statusCount = $(this).closest('.course-checklist').find('.status-count');
var $statusAmount = $(this).closest('.course-checklist').find('.status-amount');
if ($(this).attr('checked')) {
console.log('adding');
}
else {
console.log('subtracting');
}
}
});
</script>
</%block>
\ No newline at end of file
......@@ -58,7 +58,7 @@
<ul>
<li class="nav-item nav-course-tools-import"><a href="${reverse('import_course', kwargs=dict(org=ctx_loc.org, course=ctx_loc.course, name=ctx_loc.name))}">Import</a></li>
<li class="nav-item nav-course-tools-export"><a href="${reverse('export_course', kwargs=dict(org=ctx_loc.org, course=ctx_loc.course, name=ctx_loc.name))}">Export</a></li>
<li class="nav-item nav-course-tools-checklists"><a href="${reverse('checklists')}">Tasks &amp; Checklists</a></li>
<li class="nav-item nav-course-tools-checklists"><a href="${reverse('checklists', kwargs=dict(org=ctx_loc.org, course=ctx_loc.course, name=ctx_loc.name))}">Tasks &amp; Checklists</a></li>
</ul>
</div>
</div>
......
......@@ -83,7 +83,8 @@ urlpatterns = ('',
# User creation and updating views
urlpatterns += (
url(r'^ux-checklists$', 'contentstore.views.ux_checklists', name='checklists'),
url(r'^(?P<org>[^/]+)/(?P<course>[^/]+)/checklists/(?P<name>[^/]+)$', 'contentstore.views.get_checklists', name='checklists'),
# url(r'^ux-checklists$', 'contentstore.views.ux_checklists', name='checklists'),
url(r'^howitworks$', 'contentstore.views.howitworks', name='howitworks'),
url(r'^signup$', 'contentstore.views.signup', name='signup'),
......
......@@ -2,5 +2,31 @@
metadata:
display_name: Empty
start: 2020-10-10T10:00
checklists: [
{"short_description" : "Getting Started With Studio",
"items" : [{"short_description": "Add Course Team Members",
"long_description": "Grant your collaborators permission to edit your course so you can work together.",
"is_checked": false,
"action_url": "/manage_users/",
"action_text": "Edit Course Team"},
{"short_description": "Drink Whiskey",
"long_description": "Team-building activity.",
"is_checked": false,
"action_url": "/drink_alcohol",
"action_text": "Drink"}],
"completed" : false},
{"short_description" : "Launching Your Course",
"items" : [{"short_description": "Add Content",
"long_description": "Create videos and problems.",
"is_checked": false,
"action_url": "",
"action_text": ""},
{"short_description": "View Course as a Student",
"long_description": "Create a student account and view your course.",
"is_checked": false,
"action_url": "",
"action_text": ""}],
"completed" : false}
]
data: { 'textbooks' : [ ], 'wiki_slug' : null }
children: []
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment