Factored out the "No Record Available" message.
--- a/app/soc/views/helper/list_info.py Thu Jul 30 10:49:19 2009 +0200
+++ b/app/soc/views/helper/list_info.py Thu Jul 30 10:53:03 2009 +0200
@@ -22,9 +22,14 @@
]
+from django.utils.translation import ugettext
+
from soc.views.helper import redirects
+DEF_NO_RECORD_AVAILABLE_MESSAGE = ugettext('No Record Available')
+
+
def getStudentProposalInfo(ranking, proposals_keys):
"""Returns a function that returns information about the rank and assignment.
@@ -146,8 +151,8 @@
info['taken_by'] = record_entity.user.name
info['taken_on'] = record_entity.modified
else:
- info['taken_by'] = 'No Record Available'
- info['taken_on'] = 'No Record Available'
+ info['taken_by'] = DEF_NO_RECORD_AVAILABLE_MESSAGE
+ info['taken_on'] = DEF_NO_RECORD_AVAILABLE_MESSAGE
take_redirect_info = {'survey': survey_entity,
'params': survey_params}