Answer the question
In order to leave comments, you need to log in
What is the best way to implement deleting a record using DeleteView and jQueryUI?
I did the deletion of the record without reloading the page like this:
class NewsDelete(DeleteView):
model = News
def get(self, request, *args, **kwargs):
self.object = self.get_object()
self.object.delete()
return HttpResponse("OK")
Answer the question
In order to leave comments, you need to log in
There is. Only it is necessary to delete on POST or DELETE.
class NewsDelete(DeleteView):
model = News
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question