--- a/app/soc/views/helper/list_info.py Sat Apr 18 11:41:56 2009 +0000
+++ b/app/soc/views/helper/list_info.py Sat Apr 18 12:07:02 2009 +0000
@@ -22,20 +22,20 @@
]
-def getStudentProposalInfo(ranking, assigned_proposals):
+def getStudentProposalInfo(ranking, proposals_keys):
"""Returns a function that returns information about the rank and assignment.
Args:
- ranking: dict with a mapping from Student Proposal to rank
- assigned_proposals: list of proposals assigned a slot
+ ranking: dict with a mapping from Student Proposal key to rank
+ proposals_keys: list of proposal keys assigned a slot
"""
def wrapper(item, _):
"""Decorator wrapper method.
"""
- info = {'rank': ranking[item]}
+ info = {'rank': ranking[item.key()]}
- if item in assigned_proposals:
+ if item.key() in proposals_keys:
info['item_class'] = 'selected'
else:
info['item_class'] = 'normal'