Modify

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#10895 closed enhancement (worksforme)

Restrict ticket fields shown in notifications

Reported by: phooper0001@… Owned by: Steffen Hoffmann
Priority: normal Component: AnnouncerPlugin
Severity: major Keywords: announcer notification email
Cc: Trac Release: 0.12

Description

Can you restrict the number of header fields that are included on the annnouncer email, based on the ticket type ?

Attachments (0)

Change History (6)

comment:1 Changed 12 years ago by Steffen Hoffmann

Priority: highnormal
Resolution: wontfix
Status: newclosed
Summary: Header fields in announcer pluginRestrict ticket fields shown in notifications
Type: defectenhancement

I've not seen that ticket coming in, sorry.

What do you refer to by the term 'header fields'? Email headers do not resemble fields IMHO, and ticket fields are not in email header either. What you seem to ask for is restricting, what ticket fields get sent in ticket notifications, right?

This can't be done by now, and I suspect that it is not a very common demand anyway.

Finally you should rather ask such questions at our mailing list, since it is no defect, more even a clearly shaped feature request. Thanks you for your interest in this plugin, and I hope that you follow upcoming development, and that you'll still find a suitable solution for now.

Feel free to comment, but only reopen this ticket, if you can provide substantial justification on terms of use cases, please. Providing evidence for significant need, or general benefit of an implementation of your idea/request is absolutely critical for acceptance (as is not to tell developers here, what priority an issue deserves in there list of to-do's, btw).

comment:2 Changed 12 years ago by Ryan J Ollos

Keywords: announcer, notification, emailannouncer notification email

comment:3 in reply to:  1 ; Changed 12 years ago by Ryan J Ollos

Replying to hasienda:

This can't be done by now, and I suspect that it is not a very common demand anyway.

Would it be possible to accomplish this by providing a custom email template? The template is coded in Genshi, so it certainly appears possible to add logic in their to accomplish what this user wants.

I don't recall though, if AnnouncerPlugin provides a way to use a custom email template. The ability to provide a custom email template is certainly a reasonable feature request though, if it doesn't already exist. I believe that Trac allows this for its notification system, though I've never utilized the feature.

comment:4 in reply to:  3 ; Changed 12 years ago by Steffen Hoffmann

Resolution: wontfix
Status: closedreopened

Replying to rjollos:

Replying to hasienda:

This can't be done by now, and I suspect that it is not a very common demand anyway.

Would it be possible to accomplish this by providing a custom email template? The template is coded in Genshi, so it certainly appears possible to add logic in their to accomplish what this user wants.

A custom template could have additional instructions to drop some ticket fields. It would be acceptable as a quick customization hack, but not as a distributable solution IMHO.

I don't recall though, if AnnouncerPlugin provides a way to use a custom email template. The ability to provide a custom email template is certainly a reasonable feature request though, if it doesn't already exist. I believe that Trac allows this for its notification system, though I've never utilized the feature.

From dealing with Trac templates I remember, that template names must be unique within an environment. Templates in <env>/templates will get preferred, even for plugins. This is an inherited Trac feature, and a really powerful one as it seems, and it certainly works for Announcer too.

comment:5 Changed 12 years ago by Steffen Hoffmann

Resolution: worksforme
Status: reopenedclosed

So I conclude, that this is a more appropriate reason to close this ticket.

Thank you for pushing this a bit further. From here its still not trivial, but rather easy to get a custom solution, if we don't change our mind and provide an even better solution. But looking at the list of pending issues I feel like this will not happen too soon.

comment:6 in reply to:  4 Changed 12 years ago by Ryan J Ollos

Replying to hasienda:

From dealing with Trac templates I remember, that template names must be unique within an environment. Templates in <env>/templates will get preferred, even for plugins. This is an inherited Trac feature, and a really powerful one as it seems, and it certainly works for Announcer too.

Great to know that we already have a solution, and your explanation helps to piece together various bits of knowledge that I hadn't yet connected to realize what was possible here.

In case the original reporter didn't follow that entirely, I just want to be completely clear and summarize: just copy the announcer/templates/ticket_email_mimic.html template into $TRACENV/templates, and edit the template using Genshi syntax to accomplish your customization.

Feel free to ask more questions if you stumble, but the t:MailingList is the best place to reach a wide audience that can help you.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Steffen Hoffmann.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.