Re: def post in ListView

2021-11-24 Thread Lalit Suthar
oh cool :D this is looking more pretty On Thu, 25 Nov 2021 at 02:49, bnmng wrote: > Thanks, though, Lalit. > > I realized I don't event have to do what I was originally doing. I can > just do this: > > def post(self, request, *args, **kwargs): > return super().get(request, *args, **kwar

Re: def post in ListView

2021-11-24 Thread bnmng
Thanks, though, Lalit. I realized I don't event have to do what I was originally doing. I can just do this: def post(self, request, *args, **kwargs): return super().get(request, *args, **kwargs) Then the post params are still available to the queryset method def get_queryset(self

Re: def post in ListView

2021-11-24 Thread Lalit Suthar
oh my bad that is available in django rest framework only On Wed, 24 Nov 2021 at 22:41, Lalit Suthar wrote: > you can use `query_params` > > On Wed, 24 Nov 2021 at 19:04, bnmng wrote: > >> Hi everyone, >> >> Is there anything dangerous about this? >> class ItemList(ListView): >> model = It

Re: def post in ListView

2021-11-24 Thread Lalit Suthar
you can use `query_params` On Wed, 24 Nov 2021 at 19:04, bnmng wrote: > Hi everyone, > > Is there anything dangerous about this? > class ItemList(ListView): > model = Item > def post(self, request, *args, **kwargs): > self.request.GET = self.request.POST > return super().

def post in ListView

2021-11-24 Thread bnmng
Hi everyone, Is there anything dangerous about this? class ItemList(ListView): model = Item def post(self, request, *args, **kwargs): self.request.GET = self.request.POST return super().get(request, *args, **kwargs) I want to use this to accept filtering parameters from a