summaryrefslogtreecommitdiff
path: root/rt/lib/RT/Ticket_Vendor.pm
blob: 604a84aa22c8c8a84c08398d93141f82b65e017c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
package RT::Ticket;
use strict;

sub SetPriority {
  # Special case: Pass a value starting with 'R' to set priority 
  # relative to the current level.  Used for bulk updates, though 
  # it can be used anywhere else too.
  my $Ticket = shift;
  my $value = shift;
  if ( $value =~ /^R([+-]?\d+)$/ ) {
    $value = $1 + ($Ticket->Priority || 0);
  }
  $Ticket->SUPER::SetPriority($value);
}

1;