I have a ListView and a DeleteView
class MyDeleteView(DeleteView):
success_url = reverse('list')
I want the option to delete the items in the ListView. I know how to do it if I accept the confirmation page in the DeleteView, but I don't want no template in my DeleteView. I just want to delete the item and send the user back.
I guess it should be with POST parameters, but what should the HTML look like? I guess it's something like:
<form method="post" action="/delete/">
<ul>
<li>Item1 (<input type="submit" value="Delete" />)</li>
<li>Item2 (<input type="submit" value="Delete" />)</li>
<li>Item3 (<input type="submit" value="Delete" />)</li>
</ul>
</form>
Can anyone lead me in the right direction? Thank you.