I leave you two more links that may be interesting
https://stackoverflow.com/questions/41094013/when-to-use-serializers-create-and-modelviewsets-create-perform-create
https://github.com/repleo/bounca/blob/master/bounca/api/mixins.py
El jue., 16 ene. 2020 a las 2:30, Yiran Hu () escribió:
> Yes
Yes that makes sense!
On Wednesday, January 15, 2020 at 7:57:45 AM UTC-5, Jason wrote:
>
> `create` is the direct handler for any POST requests that come in. So, it
> needs to have `request` in there, because its a subclass of
> `django.views.generic.View` View handlers need to implement the
`create` is the direct handler for any POST requests that come in. So, it
needs to have `request` in there, because its a subclass of
`django.views.generic.View` View handlers need to implement the parameter
contract that Django specifes. This is hit after all post-request
middleware has
Hi Folks!
New here and thanks for being such a supportive community!
I was using a CreateAPIView and overrode the perform_create() method to add
the request user object to the ModelSerializer. Now I see that create()
method has a request in the parameter while perform_create() doesn't, but