From 04a7be0ae7a1a4ad2512a89399f0f3d058f2e34b Mon Sep 17 00:00:00 2001 From: Piotr Mitros Date: Fri, 27 Jan 2012 22:37:34 -0500 Subject: [PATCH] Fixed e-mail in URLs.py, fixed 2 gjs bugs --- courseware/capa/capa_problem.py | 2 +- courseware/capa/responsetypes.py | 4 +++- urls.py | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/courseware/capa/capa_problem.py b/courseware/capa/capa_problem.py index 46ad5e861d..a6021af3bc 100644 --- a/courseware/capa/capa_problem.py +++ b/courseware/capa/capa_problem.py @@ -133,7 +133,7 @@ class LoncapaProblem(object): for entry in problems_simple.xpath("//"+"|//".join(response_properties+entry_types)): answer = entry.get('correct_answer') if answer != None: - answer_map[entry.get('id')] = contextualize_text(answer, self.context()) + answer_map[entry.get('id')] = contextualize_text(answer, self.context) return answer_map diff --git a/courseware/capa/responsetypes.py b/courseware/capa/responsetypes.py index 3e3cefd8ab..2fbc16ed47 100644 --- a/courseware/capa/responsetypes.py +++ b/courseware/capa/responsetypes.py @@ -8,7 +8,9 @@ from django.conf import settings global_context={'random':random, 'numpy':numpy, 'math':math, - 'scipy':scipy} + 'scipy':scipy, + 'calc':calc, + 'eia':eia} class numericalresponse(object): def __init__(self, xml, context): diff --git a/urls.py b/urls.py index 6d5cfeb561..f24b2088f2 100644 --- a/urls.py +++ b/urls.py @@ -19,7 +19,7 @@ urlpatterns = ('', url(r'^activate/(?P[^/]*)$', 'auth.views.activate_account'), url(r'^$', 'auth.views.index'), url(r'^password_reset/$', 'django.contrib.auth.views.password_reset', - dict(from_email='6002-admin@mit.edu'),name='auth_password_reset'), + dict(from_email='registration@mitx.mit.edu'),name='auth_password_reset'), url(r'^password_change/$',django.contrib.auth.views.password_change,name='auth_password_change'), url(r'^password_change_done/$',django.contrib.auth.views.password_change_done,name='auth_password_change_done'), url(r'^password_reset_confirm/(?P[0-9A-Za-z]+)-(?P.+)/$',django.contrib.auth.views.password_reset_confirm,