Re: Customized Views for CRUD actions

2018-09-07 Thread Jason
I think you're mixing pieces, concepts and ideas up due to your 
unfamilarity.

django can do exactly what you want to do.  but it does it in different 
ways, and DRF adds another way to do it.  Problem is, you need to separate 
out the view layer, the transport format and the presentation layer.  View 
layer is the code responsible for handling the request and returning the 
response.  This can be in JSON, HTML, XML, etc.  Its up to your 
presentation layer to present the response in the form you deem sufficient.

from what it sounds like in your example, you're confusing the transport 
format with the presentation layer in DRF.  You need to have something in 
HTML/JS to *render* the response into something the browser can use.  The 
JSON data is not meant to be primarily human readable, but to be consumed 
by a client and transformed as the dev wants.

-- 
You received this message because you are subscribed to the Google Groups 
"Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-rest-framework+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Customized Views for CRUD actions

2018-09-06 Thread Jason
that's what the generics and mixins 
 are for

-- 
You received this message because you are subscribed to the Google Groups 
"Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-rest-framework+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.