Prelim support for combinedopenended and peergrading types
This commit is contained in:
@@ -66,7 +66,7 @@ from cms.djangoapps.models.settings.course_metadata import CourseMetadata
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
COMPONENT_TYPES = ['customtag', 'discussion', 'html', 'problem', 'video']
|
||||
COMPONENT_TYPES = ['customtag', 'discussion', 'html', 'problem', 'video', 'peergrading', 'combinedopenended']
|
||||
|
||||
# cdodge: these are categories which should not be parented, they are detached from the hierarchy
|
||||
DETACHED_CATEGORIES = ['about', 'static_tab', 'course_info']
|
||||
@@ -282,6 +282,7 @@ def edit_unit(request, location):
|
||||
component_templates = defaultdict(list)
|
||||
|
||||
templates = modulestore().get_items(Location('i4x', 'edx', 'templates'))
|
||||
log.debug(templates)
|
||||
for template in templates:
|
||||
if template.location.category in COMPONENT_TYPES:
|
||||
component_templates[template.location.category].append((
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
---
|
||||
metadata:
|
||||
display_name: Open Ended Response
|
||||
rerandomize: never
|
||||
showanswer: never
|
||||
weight: ""
|
||||
attempts: 10
|
||||
max_score: 2
|
||||
is_graded: False
|
||||
version: 1
|
||||
display_name: Test Question
|
||||
data: |
|
||||
<combinedopenended attempts="10" max_score="2" display_name = "Test Question" is_graded="True" version="1">
|
||||
<rubric>
|
||||
<rubric>
|
||||
<category>
|
||||
<description>Category 1</description>
|
||||
<option>
|
||||
The response does not incorporate what is needed for a one response.
|
||||
</option>
|
||||
<option>
|
||||
The response is correct for category 1.
|
||||
</option>
|
||||
</category>
|
||||
<category>
|
||||
<description> Hydrophobia </description>
|
||||
<option>
|
||||
The response does not incorporate what is needed for a one response.
|
||||
</option>
|
||||
<option>
|
||||
The response is correct for category 2.
|
||||
</option>
|
||||
</category>
|
||||
</rubric>
|
||||
</rubric>
|
||||
<prompt>
|
||||
<p>Why is the sky blue?</p>
|
||||
</prompt>
|
||||
<task>
|
||||
<selfassessment/>
|
||||
</task>
|
||||
<task>
|
||||
<openended min_score_to_attempt="1" max_score_to_attempt="2">
|
||||
<openendedparam>
|
||||
<initial_display>Enter essay here.</initial_display>
|
||||
<answer_display>This is the answer.</answer_display>
|
||||
<grader_payload>{"grader_settings" : "peer_grading.conf", "problem_id" : "700x/Demo"}</grader_payload>
|
||||
</openendedparam>
|
||||
</openended>
|
||||
</task>
|
||||
</combinedopenended>
|
||||
|
||||
|
||||
children: []
|
||||
@@ -0,0 +1,12 @@
|
||||
---
|
||||
metadata:
|
||||
display_name: Peer Grading Interface
|
||||
rerandomize: never
|
||||
showanswer: never
|
||||
weight: ""
|
||||
attempts: ""
|
||||
data: |
|
||||
<peergrading use_for_single_location="False" is_graded="False" display_name = "Peer Grading Panel">
|
||||
</peergrading>
|
||||
|
||||
children: []
|
||||
Reference in New Issue
Block a user