lib/RT/Transaction_Overlay.pm #fix transaction custom fields
lib/RT/Tickets_Overlay.pm #customfield date patch #SearchCustomerFields #this-month condition
lib/RT/Ticket_Overlay.pm #fix transaction custom fields
+lib/RT/Ticket_Vendor.pm #bulk increment priority
lib/RT/Users_Overlay.pm
lib/RT/Groups_Overlay.pm
lib/RT/Date.pm #this-month condition
share/html/Elements/SelectCustomerClass #SearchCustomerFields
share/html/Elements/SelectCustomerTag #SearchCustomerFields
share/html/Prefs/SavedSearches.html #saved searches
+share/html/Search/Bulk.html #bulk increment priority
share/html/Search/Build.html
share/html/Search/Results.tsv #content-type bug fix
share/html/Search/Elements/BuildFormatString
--- /dev/null
+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;
<tr><td class="label"> <&|/l&>Make subject</&>: </td>
<td class="value"> <input name="Subject" size="20" value="<% $ARGS{Subject} || '' %>"/> </td></tr>
<tr><td class="label"> <&|/l&>Make priority</&>: </td>
-<td class="value"> <& /Elements/SelectPriority, Name => "Priority", Default => $ARGS{Priority} &> </td></tr>
+% my $rel = ($ARGS{Priority} =~ s/^R//);
+<td class="value"> <& /Elements/SelectPriority, Name => "Priority", Default => $ARGS{Priority} &>
+<select name="Priority-Mode">
+<option value="absolute" <% !$rel && 'selected' %>>absolute</option>
+<option value="relative" <% $rel && 'selected' %>>relative</option>
+</select>
+</td></tr>
<tr><td class="label"> <&|/l&>Make queue</&>: </td>
<td class="value"> <& /Elements/SelectQueue, Name => "Queue", Default => $ARGS{Queue} &> </td></tr>
<tr><td class="label"> <&|/l&>Make Status</&>: </td>
$Format ||= RT->Config->Get('DefaultSearchResultFormat');
# inject _CHECKBOX to the first field.
-$Format =~ s/'?([^']+)'?,/'___CHECKBOX__$1',/;
+$Format =~ s/'?([^']+)'?,/'___CHECKBOX__$1',/; #'
my $Tickets = RT::Tickets->new( $session{'CurrentUser'} );
$Tickets->FromSQL($Query);
my $cf_add_keys;
@$cf_add_keys = grep { /^Bulk-Add-CustomField/ } keys %ARGS;
+if ( defined($ARGS{'Priority'})
+ and ($ARGS{'Priority-Mode'} || '') eq 'relative' ) {
+ # magic in Ticket::SetPriority
+ $ARGS{'Priority'} = 'R'.$ARGS{'Priority'};
+}
+delete $ARGS{'Priority-Mode'};
+
unless ( $ARGS{'AddMoreAttach'} ) {
# Add session attachments if any to be processed by ProcessUpdateMessage
$ARGS{'UpdateAttachments'} = $session{'Attachments'} if ( $session{'Attachments'} );