[[PageOutline(2-5,Contents,pullout)]] = Disable email notifications == Description This plugin provides a link (in the contextual navigation menu) to toggle on and off sending emails for your ticket changes. The purpose is to reduce superfluous emails for ticket changes that the author deems low-value. [[Image(quiet.png)]] The toggling is handled via AJAX, so you can remain on the same page and not disrupt any current work. The toggle link will appear on {{{/newticket}}}, {{{/ticket}}}, {{{/query}}}, and {{{/report}}} pages since ticket changes are possible on all of these, eg via [TracBatchModify BatchModify] or [GridModifyPlugin GridModify]. This plugin requires AnnouncerPlugin for Trac < 1.2. For Trac 1.2 and later, this plugin works without AnnouncerPlugin. == Bugs/Feature Requests Existing bugs and feature requests for QuietPlugin are [report:9?COMPONENT=QuietPlugin here]. If you have any issues, create a [/newticket?component=QuietPlugin new ticket]. [[TicketQuery(component=QuietPlugin,group=type,format=progress)]] == Download Download the zipped source from [export:quietplugin here]. The plugin is also available on [pypi:TracQuiet PyPI]. == Source You can check out QuietPlugin from [/svn/quietplugin here] using Subversion, or [source:quietplugin browse the source] with Trac. == Installation The following describes how to install the plugin in Trac 1.2. To install the plugin for Trac < 1.0 with AnnouncerPlugin see QuietPlugin@17. 1. Install the plugin after downloading and unzipping: {{{#!sh $ pip install TracQuiet }}} 1. Restart Trac's web server. 1. Enable the plugin and disable `EmailDistributor` in your `trac.ini` file: {{{#!ini [components] trac.notification.mail.EmailDistributor = disabled quiet.* = enabled }}} Alternatively, you can use the Trac Web Admin GUI to enable/disable the components. The `trac.ini` lines above ensure that the plugin uses its own email distributor. This distributor effectively wraps the Trac's !EmailDistributor with an extra check to see if the user entered quiet mode or not. == Configuration There are the following optional steps for configuration: 1. Customize the quiet mode labels in {{{trac.ini}}}: {{{#!ini [quiet] enter_label = Enter Quiet Mode leave_label = Leave Quiet Mode }}} 1. Add the {{{QUIET_MODE}}} permission to users or groups as appropriate on the Admin > Permissions page. == Examples The following are typical scenarios of how this plugin could be used: * During planning, I can now avoid barraging people with emails when I move large batches of tickets from one milestone to another using [wiki:BatchModifyPlugin BatchModify]. * I want to make a minor fix to a ticket's description that doesn't call for yet another email to be sent - enter quiet mode! * I'm triaging many tickets in a [wiki:QueuesPlugin Queue report] with new positions using [wiki:GridModifyPlugin GridModify] and I don't want an email sent for each change. * I'm managing dependencies using the [wiki:AnalyzePlugin Analyze plugin] and don't want to inundate the team with emails of its fixes. === Trigger quiet mode To help you remember to enter quiet mode for the above use cases or similar ones, you can create trigger rules on [wikipedia:Document_Object_Model DOM] elements that will prompt you to enter or leave quiet mode (if you're not already in that state): {{{#!ini [quiet] 1.selector = #analyzebutton 1.action = enter 2.selector = #batchmod_submit 2.action = enter 2.submit = true 3.selector = #propertyform[action*=ticket] .buttons input[name=submit] 3.action = leave 3.only_if = #comment:first=.+ 3.submit = true }}} The above example defines three trigger rules: 1. When the "Analyze..." button is clicked, prompt to enter quiet mode. 1. When the "Batch Modify" button is clicked, prompt to enter quiet mode (and prevent the submission - but then they can submit again). 1. When a ticket's "Submit changes" button is clicked ''and'' there's some text in the comment field, then prompt to enter quiet mode (and prevent the submission - but then they can submit again). The {{{only_if}}} option can either be just a CSS selector or also include an expected regex value (eg the {{{=.+}}} above). * If it is a CSS selector, then the selector must exist. * If it is an expected regex value, then the selected item's jQuery {{{val()}}} must match the expected value. == Recent Changes [[ChangeLog(quietplugin, 3)]] == Author/Contributors '''Author:''' [wiki:robguttman] [[BR]] '''Maintainer:''' [[Maintainer]] [[BR]] '''Contributors:''' rjollos