Opened 9 years ago

Closed 9 years ago

#25859 closed New feature (needsinfo)

DeleteView should inherit from a more generic ConfirmView

Reported by: windwarrior Owned by: nobody
Component: Generic views Version: dev
Severity: Normal Keywords: DeleteView, ConfirmView
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


When developing applications I am very content by the CBV's that are available in django. However, I am missing a single viewtype. Many actions need explicit confirmation by users, deleting objects, publishing objects, etc.

Django provides a DeleteView to cover the delete case, but publishing an object (which can be a sensitive action that needs confirmation) should not be modeled as a DeleteView as it shouldnt respond to HTTP delete. Therefore I vouch for splitting the DeleteView in a more generic ConfirmView (that you can then use for the publishing case), and altering DeleteView to inherit from it and respond to a HTTP delete.

I am willing to implement this, but I wanted to know whether you feel the same before I start programming :).

Change History (3)

comment:1 by Tim Graham, 9 years ago

Hi, design decisions are usually made on the django-developers mailing list. I would post this idea there to get feedback, although I think a proof-of-concept implementation might be needed to better understand the proposal.

comment:2 by windwarrior, 9 years ago

Thank you for your swiftly response, I will start working on a POC then. You will hear from me soon on the relevant mailing list :)!

comment:3 by Tim Graham, 9 years ago

Resolution: needsinfo
Status: newclosed

Closing, pending the mailing list discussion.

Note: See TracTickets for help on using tickets.
Back to Top