Re: Complex lookups and SelectMultiple widget

2008-12-08 Thread issya
Thank you for the reply. I tried going the route of using the below. Is your way better? Since 'in' needs a list as an argument and SelectMultiple returns a list: if request.method == "POST" or request.GET.get('page', ''): search_form = SearchForm(request.POST) if

Re: Complex lookups and SelectMultiple widget

2008-12-07 Thread krylatij
> I am working on a search form that has a SelectMultiple widget. What > would be the best way to make a complex lookup with the SelectMultiple > widget? try this: try: district_ids = [int(x) for x in request.GET.getlist('district')] if len(district_ids) == 0: district_ids = [

Complex lookups and SelectMultiple widget

2008-12-07 Thread issya
I am working on a search form that has a SelectMultiple widget. What would be the best way to make a complex lookup with the SelectMultiple widget? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group.