Re: Generic CBV DeleteView GET csrf_token

2019-03-14 Thread Chetan Ganji
Frameworks dont work as we want them too :P We have to understand how the defaults are implemented then make the changes as necessary ;-) If it can be customized, great! otherwise learn and use a different framework, LOLZ ;-) Regards, Chetan Ganji +91-900-483-4183 ganji.che...@gmail.com http://ry

Re: Generic CBV DeleteView GET csrf_token

2019-03-14 Thread B
Thanks. I have things working fine under Ajax. This particular scenario is an "odd one" since performing a GET on a delete view isn't common, but it is implemented by Django. It is helpful for testing, but perhaps the right approach is to "disable" get for the DeleteView and be done with it. My

Re: Generic CBV DeleteView GET csrf_token

2019-03-14 Thread Chetan Ganji
https://www.django-rest-framework.org/topics/ajax-csrf-cors/ https://docs.djangoproject.com/en/2.1/ref/csrf/#ajax Regards, Chetan Ganji +91-900-483-4183 ganji.che...@gmail.com http://ryucoder.in

Generic CBV DeleteView GET csrf_token

2019-03-14 Thread B
I'm implementing a DeleteView, and for completion I would like to provide the functionality indicated here: https://docs.djangoproject.com/en/2.1/ref/class-based-views/generic-editing/#deleteview *If this view is fetched via GET, it will display a confirmation page that should contain a form th