diff options
author | ankitjavalkar | 2020-04-03 12:25:03 +0530 |
---|---|---|
committer | GitHub | 2020-04-03 12:25:03 +0530 |
commit | 1ef1835c1adf24193cf4b58ccc4c1598f0565c43 (patch) | |
tree | 3b2794b34e965b8fb3cdb93f3149020efe613c10 /yaksh/views.py | |
parent | d749a166c86db15f580b9e07eb65fe3344d9881a (diff) | |
parent | fbeb3428426691c29d4dd3f38b2245f21b5673ef (diff) | |
download | online_test-1ef1835c1adf24193cf4b58ccc4c1598f0565c43.tar.gz online_test-1ef1835c1adf24193cf4b58ccc4c1598f0565c43.tar.bz2 online_test-1ef1835c1adf24193cf4b58ccc4c1598f0565c43.zip |
Merge pull request #671 from ankitjavalkar/fix-stdio
Allow stdio expected input to be optional and miscellanous UI fixes
Diffstat (limited to 'yaksh/views.py')
-rw-r--r-- | yaksh/views.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/yaksh/views.py b/yaksh/views.py index 51f6e54..9efcbe9 100644 --- a/yaksh/views.py +++ b/yaksh/views.py @@ -103,8 +103,9 @@ def get_html_text(md_text): def formfield_callback(field): - if (isinstance(field, models.TextField) and field.name == 'expected_output' - or field.name == 'expected_input'): + if (isinstance(field, models.TextField) and field.name == 'expected_input'): + return fields.CharField(strip=False, required = False) + if (isinstance(field, models.TextField) and field.name == 'expected_output'): return fields.CharField(strip=False) return field.formfield() |