Add 'value' to filesubmission template

This commit is contained in:
kimth
2012-08-03 15:49:30 -04:00
parent c25eded4fc
commit 9d52c43286
2 changed files with 2 additions and 2 deletions

View File

@@ -307,7 +307,7 @@ def filesubmission(element, value, status, render_template, msg=''):
Upload a single file (e.g. for programming assignments)
'''
eid = element.get('id')
context = { 'id': eid, 'state': status, 'msg': msg, }
context = { 'id': eid, 'state': status, 'msg': msg, 'value': value, }
html = render_template("filesubmission.html", context)
return etree.XML(html)

View File

@@ -1,5 +1,5 @@
<section id="filesubmission_${id}" class="filesubmission">
<input type="file" name="input_${id}" id="input_${id}" /><br />
<input type="file" name="input_${id}" id="input_${id}" value="${value}" /><br />
% if state == 'unsubmitted':
<span class="unanswered" style="display:inline-block;" id="status_${id}"></span>
% elif state == 'correct':