From 92ae5b3f0bfb6ad90fa984dd220172e6616a5e86 Mon Sep 17 00:00:00 2001 From: Dusty Phillips Date: Tue, 7 Oct 2008 14:53:56 -0400 Subject: need better than ids for options --- main/utils.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'main') diff --git a/main/utils.py b/main/utils.py index eb0cb2a3..f31689f8 100644 --- a/main/utils.py +++ b/main/utils.py @@ -15,5 +15,8 @@ def render_response(req, *args, **kwargs): kwargs['context_instance'] = RequestContext(req) return render_to_response(*args, **kwargs) +#utility to make a pair of django choices +make_choice = lambda l: [(str(m), str(m)) for m in l] + # vim: set ts=4 sw=4 et: -- cgit v1.2.3-55-g3dc8