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
e9468a0e
Commit
e9468a0e
authored
May 20, 2012
by
Piotr Mitros
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Modular refactor: Very minor changes (comments, etc.)
parent
d95a5e46
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
1 deletions
+7
-1
djangoapps/courseware/capa/capa_problem.py
+3
-1
djangoapps/courseware/capa/inputtypes.py
+4
-0
No files found.
djangoapps/courseware/capa/capa_problem.py
View file @
e9468a0e
...
...
@@ -240,7 +240,7 @@ class LoncapaProblem(object):
# used to be
# if problemtree.tag in html_special_response:
if
problemtree
.
tag
in
inputtypes
.
SimpleInput
.
ge
t_xml_tags
():
if
problemtree
.
tag
in
inputtypes
.
get_inpu
t_xml_tags
():
# status is currently the answer for the problem ID for the input element,
# but it will turn into a dict containing both the answer and any associated message
# for the problem ID for the input element.
...
...
@@ -267,6 +267,8 @@ class LoncapaProblem(object):
# print "[courseware.capa.capa_problem.extract_html] msg = ",msg
# do the rendering
# This should be broken out into a helper function
# that handles all input objects
render_object
=
inputtypes
.
SimpleInput
(
system
=
self
.
system
,
xml
=
problemtree
,
state
=
{
'value'
:
value
,
...
...
djangoapps/courseware/capa/inputtypes.py
View file @
e9468a0e
...
...
@@ -32,6 +32,10 @@ from lxml import etree
from
mitxmako.shortcuts
import
render_to_string
def
get_input_xml_tags
():
''' Eventually, this will be for all registered input types '''
return
SimpleInput
.
get_xml_tags
()
class
SimpleInput
():
# XModule
''' Type for simple inputs -- plain HTML with a form element
State is a dictionary with optional keys:
...
...
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