RT::Action::LinearEscalate - will move a ticket's priority toward its final priority.
LinearEscalate is a ScripAction that will move a ticket's priority from its initial priority to its final priority linearly as the ticket approaches its due date.
It's intended to be called by an RT escalation tool. One such tool is called rt-crontool and is located in $RTHOME/bin (see rt-crontool -h for more details).
rt-crontool -h
To install this package run:
perl Makefile.PL make install
Once the ScripAction is installed, the following script in "cron" will get tickets to where they need to be:
rt-crontool --search RT::Search::FromSQL --search-arg \ "(Status='new' OR Status='open' OR Status = 'stalled')" \ --action RT::Action::LinearEscalate
The Starts date is associated with intial ticket's priority or the Created field if the former is not set. End of interval is the Due date. Tickets without due date are not updated.
Initial and Final priorities are controlled by queue's options and can be defined using the web UI via Configuration tab. This action should handle correctly situations when initial priority is greater than final.
LinearEscalate's behavior can be controlled by two options:
You cannot set "UpdateLastUpdated" to false unless "RecordTransaction" is also false. Well, you can, but we'll just ignore you.
You can set this options using either in RT_SiteConfig.pm, as action argument in call to the rt-crontool or in DB if you want to use the action in scrips.
You should prefix options with LinearEscalate_ in the config:
LinearEscalate_
Set( $LinearEscalate_RecordTransaction, 1 ); Set( $LinearEscalate_UpdateLastUpdated, 1 );
From a shell you can use the following command:
rt-crontool --search RT::Search::FromSQL --search-arg \ "(Status='new' OR Status='open' OR Status = 'stalled')" \ --action RT::Action::LinearEscalate \ --action-arg "RecordTransaction: 1"
This ScripAction uses RT's internal RT::Ticket::_Set call to set ticket priority without running scrips or recording a transaction on each update.
Kevin Riggle <kevinr@bestpractical.com>
Ruslan Zakirov <ruz@bestpractical.com>
To install RT::Action::LinearEscalate, copy and paste the appropriate command in to your terminal.
cpanm
cpanm RT::Action::LinearEscalate
CPAN shell
perl -MCPAN -e shell install RT::Action::LinearEscalate
For more information on module installation, please visit the detailed CPAN module installation guide.