diff options
Diffstat (limited to 'rt/share/html/Elements')
-rw-r--r-- | rt/share/html/Elements/AddCustomers | 2 | ||||
-rw-r--r-- | rt/share/html/Elements/ColumnMap | 8 | ||||
-rw-r--r-- | rt/share/html/Elements/EditCustomField | 2 | ||||
-rwxr-xr-x | rt/share/html/Elements/Header | 3 | ||||
-rw-r--r-- | rt/share/html/Elements/HeaderJavascript | 2 | ||||
-rwxr-xr-x | rt/share/html/Elements/ListActions | 2 | ||||
-rwxr-xr-x | rt/share/html/Elements/MessageBox | 3 | ||||
-rw-r--r-- | rt/share/html/Elements/QueueSummaryByStatus | 10 | ||||
-rw-r--r-- | rt/share/html/Elements/RT__CustomField/ColumnMap | 4 | ||||
-rwxr-xr-x | rt/share/html/Elements/SelectWatcherType | 2 | ||||
-rwxr-xr-x | rt/share/html/Elements/Tabs | 2 |
11 files changed, 23 insertions, 17 deletions
diff --git a/rt/share/html/Elements/AddCustomers b/rt/share/html/Elements/AddCustomers index 9828d7d53..6517db42c 100644 --- a/rt/share/html/Elements/AddCustomers +++ b/rt/share/html/Elements/AddCustomers @@ -41,7 +41,7 @@ my @Customers = (); if ( $CustomerString ) { @Customers = &RT::URI::freeside::smart_search( 'search' => $CustomerString, - 'no_fuzzy_on_exact' => 1, #pref? + 'no_fuzzy_on_exact' => ! $FS::CurrentUser::CurrentUser->option('enable_fuzzy_on_exact'), ); } diff --git a/rt/share/html/Elements/ColumnMap b/rt/share/html/Elements/ColumnMap index b9c3b4bc8..f268a5d1c 100644 --- a/rt/share/html/Elements/ColumnMap +++ b/rt/share/html/Elements/ColumnMap @@ -118,7 +118,7 @@ my $COLUMN_MAP = { CheckBox => { title => sub { my $name = $_[1] || 'SelectedTickets'; - my $checked = $m->request_args->{ $name .'All' }? 'checked="checked"': ''; + my $checked = $DECODED_ARGS->{ $name .'All' }? 'checked="checked"': ''; return \qq{<input type="checkbox" name="}, $name, \qq{All" value="1" $checked onclick="setCheckbox(this.form, }, @@ -130,9 +130,9 @@ my $COLUMN_MAP = { my $name = $_[2] || 'SelectedTickets'; return \qq{<input type="checkbox" name="}, $name, \qq{" value="$id" checked="checked" />} - if $m->request_args->{ $name . 'All'}; + if $DECODED_ARGS->{ $name . 'All'}; - my $arg = $m->request_args->{ $name }; + my $arg = $DECODED_ARGS->{ $name }; my $checked = ''; if ( $arg && ref $arg ) { $checked = 'checked="checked"' if grep $_ == $id, @$arg; @@ -149,7 +149,7 @@ my $COLUMN_MAP = { my $id = $_[0]->id; my $name = $_[2] || 'SelectedTicket'; - my $arg = $m->request_args->{ $name }; + my $arg = $DECODED_ARGS->{ $name }; my $checked = ''; $checked = 'checked="checked"' if $arg && $arg == $id; return \qq{<input type="radio" name="}, $name, \qq{" value="$id" $checked />}; diff --git a/rt/share/html/Elements/EditCustomField b/rt/share/html/Elements/EditCustomField index b74c4844e..8b87fd425 100644 --- a/rt/share/html/Elements/EditCustomField +++ b/rt/share/html/Elements/EditCustomField @@ -71,7 +71,7 @@ if ( $Object && $Object->id ) { # Always fill $Default with submited values if it's empty if ( ( !defined $Default || !length $Default ) && $DefaultsFromTopArguments ) { - my %TOP = $m->request_args; + my %TOP = %$DECODED_ARGS; $Default = $TOP{ $NamePrefix .$CustomField->Id . '-Values' } || $TOP{ $NamePrefix .$CustomField->Id . '-Value' }; } diff --git a/rt/share/html/Elements/Header b/rt/share/html/Elements/Header index 1830c4bf2..65d06f879 100755 --- a/rt/share/html/Elements/Header +++ b/rt/share/html/Elements/Header @@ -130,7 +130,8 @@ if ($m->comp_exists($stylesheet_plugin) ) { # $m->callback( %ARGS, CallbackName => 'Head' ); $head .= $m->scomp( '/Elements/Callback', _CallbackName => 'Head', %ARGS ); -my $etc = qq[ class="\L$style" ]; +my $sbs = RT->Config->Get("UseSideBySideLayout", $session{'CurrentUser'}) ? ' sidebyside' : ''; +my $etc = qq[ class="\L$style$sbs" ]; $etc .= qq[ id="comp-$id"] if $id; </%INIT> diff --git a/rt/share/html/Elements/HeaderJavascript b/rt/share/html/Elements/HeaderJavascript index 28788db57..d5741f4e6 100644 --- a/rt/share/html/Elements/HeaderJavascript +++ b/rt/share/html/Elements/HeaderJavascript @@ -67,7 +67,7 @@ $onload => undef % } % if ( $RichText and RT->Config->Get('MessageBoxRichText', $session{'CurrentUser'})) { - jQuery().ready(function () { ReplaceAllTextareas(<%$m->request_args->{'CKeditorEncoded'} || 0 |n,j%>) }); + jQuery().ready(function () { ReplaceAllTextareas(<%$DECODED_ARGS->{'CKeditorEncoded'} || 0 |n,j%>) }); % } --></script> <%ARGS> diff --git a/rt/share/html/Elements/ListActions b/rt/share/html/Elements/ListActions index 999d3fe5b..8929ff731 100755 --- a/rt/share/html/Elements/ListActions +++ b/rt/share/html/Elements/ListActions @@ -65,7 +65,7 @@ if ( ref( $session{'Actions'}{''} ) eq 'ARRAY' ) { unshift @actions, @{ delete $session{'Actions'}{''} }; } -my $actions_pointer = $m->request_args->{'results'}; +my $actions_pointer = $DECODED_ARGS->{'results'}; if ($actions_pointer && ref( $session{'Actions'}->{$actions_pointer} ) eq 'ARRAY' ) { unshift @actions, @{ delete $session{'Actions'}->{$actions_pointer} }; diff --git a/rt/share/html/Elements/MessageBox b/rt/share/html/Elements/MessageBox index 61995e057..69227bfa9 100755 --- a/rt/share/html/Elements/MessageBox +++ b/rt/share/html/Elements/MessageBox @@ -46,7 +46,7 @@ %# %# END BPS TAGGED BLOCK }}} <textarea autocomplete="off" class="messagebox" <% $width_attr %>="<% $Width %>" rows="<% $Height %>" <% $wrap_type |n %> name="<% $Name %>" id="<% $Name %>">\ -% $m->comp('/Articles/Elements/IncludeArticle', %ARGS); +% $m->comp('/Articles/Elements/IncludeArticle', %ARGS) if $IncludeArticle; % $m->callback( %ARGS, SignatureRef => \$signature ); <% $Default || '' %><% $message %><% $signature %></textarea> % $m->callback( %ARGS, CallbackName => 'AfterTextArea' ); @@ -89,4 +89,5 @@ $Width => RT->Config->Get('MessageBoxWidth', $session{'CurrentUser'} $Height => RT->Config->Get('MessageBoxHeight', $session{'CurrentUser'} ) || 15 $Wrap => RT->Config->Get('MessageBoxWrap', $session{'CurrentUser'} ) || 'SOFT' $IncludeSignature => RT->Config->Get('MessageBoxIncludeSignature'); +$IncludeArticle => 1; </%ARGS> diff --git a/rt/share/html/Elements/QueueSummaryByStatus b/rt/share/html/Elements/QueueSummaryByStatus index 09f274f74..f649d2850 100644 --- a/rt/share/html/Elements/QueueSummaryByStatus +++ b/rt/share/html/Elements/QueueSummaryByStatus @@ -122,9 +122,13 @@ my $statuses = {}; use RT::Report::Tickets; my $report = RT::Report::Tickets->new( RT->SystemUser ); -my $query = @queues - ? join(' OR ', map "Queue = ".$_->{id}, @queues) - : 'id < 0'; +my $query = + "(". + join(" OR ", map {s{(['\\])}{\\$1}g; "Status = '$_'"} @statuses) #' + .") AND (". + join(' OR ', map "Queue = ".$_->{id}, @queues) + .")"; +$query = 'id < 0' unless @queues; $report->SetupGroupings( Query => $query, GroupBy => [qw(Status Queue)] ); while ( my $entry = $report->Next ) { diff --git a/rt/share/html/Elements/RT__CustomField/ColumnMap b/rt/share/html/Elements/RT__CustomField/ColumnMap index ecb219d9e..b04398434 100644 --- a/rt/share/html/Elements/RT__CustomField/ColumnMap +++ b/rt/share/html/Elements/RT__CustomField/ColumnMap @@ -118,7 +118,7 @@ my $COLUMN_MAP = { RemoveCheckBox => { title => sub { my $name = 'RemoveCustomField'; - my $checked = $m->request_args->{ $name .'All' }? 'checked="checked"': ''; + my $checked = $DECODED_ARGS->{ $name .'All' }? 'checked="checked"': ''; return \qq{<input type="checkbox" name="}, $name, \qq{All" value="1" $checked onclick="setCheckbox(this.form, }, @@ -130,7 +130,7 @@ my $COLUMN_MAP = { return '' if $_[0]->IsApplied; my $name = 'RemoveCustomField'; - my $arg = $m->request_args->{ $name }; + my $arg = $DECODED_ARGS->{ $name }; my $checked = ''; if ( $arg && ref $arg ) { diff --git a/rt/share/html/Elements/SelectWatcherType b/rt/share/html/Elements/SelectWatcherType index 44beee00d..4f1df60b2 100755 --- a/rt/share/html/Elements/SelectWatcherType +++ b/rt/share/html/Elements/SelectWatcherType @@ -56,7 +56,7 @@ <%INIT> my @types; -if ($Scope =~ 'queue') { +if ($Scope =~ /queue/) { @types = RT::Queue->ManageableRoleGroupTypes; } else { diff --git a/rt/share/html/Elements/Tabs b/rt/share/html/Elements/Tabs index 3193b488d..3aac9d803 100755 --- a/rt/share/html/Elements/Tabs +++ b/rt/share/html/Elements/Tabs @@ -845,7 +845,7 @@ my $build_selfservice_nav = sub { } elsif ( $queue_id ) { Menu->child( new => title => loc('New ticket'), path => '/SelfService/Create.html?Queue=' . $queue_id ); } - my $tickets = Menu->child( tickets => title => loc('Tickets')); + my $tickets = Menu->child( tickets => title => loc('Tickets'), path => '/SelfService/' ); $tickets->child( open => title => loc('Open tickets'), path => '/SelfService/' ); $tickets->child( closed => title => loc('Closed tickets'), path => '/SelfService/Closed.html' ); |