I found this DeleteView. Anyone can tell me what return HttpResponseNotAllowed(['POST'])is for? Should I add it to my own DeleteView as well?
class DiscountDelete(AdminPermissionRequiredMixin, DeleteView):
model = Discount
def get(self, *args, **kwargs):
return HttpResponseNotAllowed(['POST'])