Re: Request params problem

2005-12-19 Thread Daniel Poelzleithner
plisk wrote: > Yeah, its OK to have more than one value of the same param and wrap all > of them in the list. But when you have only one parameter value passed > making a list for it is at least inconsistent with the value you get > from request.GET['param'] which is just a scalar and this also br

Re: Request params problem

2005-12-19 Thread plisk
I see, but what you get on admin forms from GET is hardly expected. So i guess this part in add_stage should be fixed ? I'll file a ticket for it. Lines 432-436 of django/contrib/admin/views/main.py # Add default data. new_data = manipulator.flatten_data() # Override the

Re: Request params problem

2005-12-19 Thread Adrian Holovaty
On 12/19/05, plisk <[EMAIL PROTECTED]> wrote: > Is it expected behaviour when opening /foo/?test=1 request.GET['test'] > returns 1, but request.GET returns {'test': ['1']}, where '1' is > enclosed in the list ? Shouldn't it also be just {'test': '1'} ? > Because of this you can see on the add form

Re: Request params problem

2005-12-19 Thread plisk
Yeah, its OK to have more than one value of the same param and wrap all of them in the list. But when you have only one parameter value passed making a list for it is at least inconsistent with the value you get from request.GET['param'] which is just a scalar and this also breaks some parts in ad

Re: Request params problem

2005-12-19 Thread Dody Suria Wijaya
Isn't it's permissible to have multiple parameter names in HTML? like: /foo/?id=1&id=2 --> {'id':['1','2']} instead of overwriting each other... plisk wrote: Hi all, Is it expected behaviour when opening /foo/?test=1 request.GET['test'] returns 1, but request.GET returns {'test': ['1']}, wh

Request params problem

2005-12-19 Thread plisk
Hi all, Is it expected behaviour when opening /foo/?test=1 request.GET['test'] returns 1, but request.GET returns {'test': ['1']}, where '1' is enclosed in the list ? Shouldn't it also be just {'test': '1'} ? Because of this you can see on the add forms in admin in text fields values like ['bar']