Commit 37ae7afb by ichuang

Merge pull request #92 from MITx/dogfood-xmodule

fix dogfood wrt lms / xmodule reorg; fix textinput_dynamath call
parents bd2a44ad 9d0dfd2f
...@@ -206,7 +206,7 @@ def textline(element, value, state, render_template, msg=""): ...@@ -206,7 +206,7 @@ def textline(element, value, state, render_template, msg=""):
Simple text line input, with optional size specification. Simple text line input, with optional size specification.
''' '''
if element.get('math') or element.get('dojs'): # 'dojs' flag is temporary, for backwards compatibility with 8.02x if element.get('math') or element.get('dojs'): # 'dojs' flag is temporary, for backwards compatibility with 8.02x
return SimpleInput.xml_tags['textline_dynamath'](element,value,state,msg) return SimpleInput.xml_tags['textline_dynamath'](element,value,state,render_template,msg)
eid=element.get('id') eid=element.get('id')
count = int(eid.split('_')[-2])-1 # HACK count = int(eid.split('_')[-2])-1 # HACK
size = element.get('size') size = element.get('size')
......
...@@ -5,7 +5,7 @@ import string ...@@ -5,7 +5,7 @@ import string
import traceback import traceback
from django.conf import settings from django.conf import settings
import courseware.capa.capa_problem as lcp import capa.capa_problem as lcp
from dogfood.views import update_problem from dogfood.views import update_problem
def GenID(length=8, chars=string.letters + string.digits): def GenID(length=8, chars=string.letters + string.digits):
......
...@@ -21,7 +21,6 @@ from django.http import HttpResponse ...@@ -21,7 +21,6 @@ from django.http import HttpResponse
from django.shortcuts import redirect from django.shortcuts import redirect
from mitxmako.shortcuts import render_to_response, render_to_string from mitxmako.shortcuts import render_to_response, render_to_string
import courseware.capa.calc
import track.views import track.views
from lxml import etree from lxml import etree
...@@ -34,7 +33,8 @@ from util.cache import cache ...@@ -34,7 +33,8 @@ from util.cache import cache
from util.views import accepts from util.views import accepts
import courseware.content_parser as content_parser import courseware.content_parser as content_parser
import courseware.modules #import courseware.modules
import xmodule
log = logging.getLogger("mitx.courseware") log = logging.getLogger("mitx.courseware")
...@@ -184,7 +184,7 @@ def quickedit(request, id=None, qetemplate='quickedit.html',coursename=None): ...@@ -184,7 +184,7 @@ def quickedit(request, id=None, qetemplate='quickedit.html',coursename=None):
filestore = OSFS(settings.DATA_DIR + xp), filestore = OSFS(settings.DATA_DIR + xp),
#role = 'staff' if request.user.is_staff else 'student', # TODO: generalize this #role = 'staff' if request.user.is_staff else 'student', # TODO: generalize this
) )
instance=courseware.modules.get_module_class(module)(system, instance=xmodule.get_module_class(module)(system,
xml, xml,
id, id,
state=None) state=None)
......
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