From f2a797b9cc0e9a6053399356e9e8cae22e553c9c Mon Sep 17 00:00:00 2001 From: mark Date: Mon, 16 May 2011 23:28:19 +0000 Subject: increment priority via bulk ticket update, #12901 --- rt/share/html/Search/Bulk.html | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'rt/share/html') diff --git a/rt/share/html/Search/Bulk.html b/rt/share/html/Search/Bulk.html index e2b757499..84f2c8230 100755 --- a/rt/share/html/Search/Bulk.html +++ b/rt/share/html/Search/Bulk.html @@ -111,7 +111,13 @@ <&|/l&>Make subject: <&|/l&>Make priority: - <& /Elements/SelectPriority, Name => "Priority", Default => $ARGS{Priority} &> +% my $rel = ($ARGS{Priority} =~ s/^R//); + <& /Elements/SelectPriority, Name => "Priority", Default => $ARGS{Priority} &> + + <&|/l&>Make queue: <& /Elements/SelectQueue, Name => "Queue", Default => $ARGS{Queue} &> <&|/l&>Make Status: @@ -283,7 +289,7 @@ $Page ||= 1; $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); @@ -332,6 +338,13 @@ my $cf_del_keys; 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'} ); -- cgit v1.2.1