OnWatcherChange: Difference between revisions

From Request Tracker Wiki
Jump to navigation Jump to search
m (2 revisions imported)
(No difference)

Revision as of 15:15, 6 April 2016

This simple scrip condition triggers when a Cc is added to a ticket.

my $transactionType = $self->TransactionObj->Type;
my $watcherType = $self->TransactionObj->Field;
if (($transactionType eq 'AddWatcher') and ($watcherType eq 'Cc')) {
  return 1;
}
  return undef;

Just change "Cc" in line 3 to "AdminCc" to look for that change. Original version by Taan posted to rt-users at http://www.gossamer-threads.com/lists/rt/users/62335#62335

To trigger on the removal of a watcher, change "AddWatcher" in line 3 to "DelWatcher".