Opened 5 years ago

Closed 3 years ago

#12684 closed New feature (duplicate)

Have callback for email creation in generic views sending emails

Reported by: zigarn Owned by: nobody
Component: Generic views Version: 1.1
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

I'd like to use EmailMultiAlternatives mails for my mails to have multipart with text & HTML (for nice looking mails but with simple text support).
But with generic views (and forms) like django.contrib.auth.views.password_reset, I can only give an email_template_name.

It would be nice to have a create_email callback to let me create the Email object that the view send.

Change History (4)

comment:1 Changed 5 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

Agreed with the use case, but the right solution would be to make the mail sending a configurable part of the PasswordResetForm.

comment:2 Changed 4 years ago by mattmcc

  • Severity set to Normal
  • Type set to New feature

comment:3 Changed 4 years ago by thejaswi_puthraya

  • Component changed from Uncategorized to Generic views
  • Easy pickings unset
  • UI/UX unset

comment:4 Changed 3 years ago by aaugustin

  • Resolution set to duplicate
  • Status changed from new to closed

The generic views don't send email — there's a confusion somewhere.

The concrete problem you're describing is tracked in #17431, with a more detailed description.

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