[Rt-commit] r2413 - in rt/branches/PLATANO-EXPERIMENTAL-CSS: .
html/Admin/Elements html/Elements html/Ticket
html/Ticket/Elements lib/RT lib/RT/Action lib/RT/Interface
jesse at bestpractical.com
jesse at bestpractical.com
Mon Mar 14 02:57:37 EST 2005
Author: jesse
Date: Mon Mar 14 02:57:36 2005
New Revision: 2413
Modified:
rt/branches/PLATANO-EXPERIMENTAL-CSS/ (props changed)
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripAction
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripCondition
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Elements/Submit
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Display.html
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowMessageStanza
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowTransaction
rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/Tabs
rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Action/CreateTickets.pm
rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Interface/Web.pm
rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Record.pm
Log:
r8573 at hualien: jesse | 2005-03-14 02:40:49 -0500
r8460 at hualien: jesse | 2005-03-14 02:25:00 -0500
r4102 at hualien: jesse | 2005-02-07 12:20:01 -0500
RT-Ticket: 6415
RT-Status: resolved
RT-Update: correspond
A bunch of small fixes to avoid minor warnings in the RT code. --Dave Rolsky
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripAction
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripAction (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripAction Mon Mar 14 02:57:36 2005
@@ -45,11 +45,11 @@
%# END BPS TAGGED BLOCK }}}
<SELECT NAME=<%$Name%>>
<OPTION VALUE=""
-<% $Default eq undef && 'SELECTED' %>
+<% ! defined $Default && 'SELECTED' %>
>-</OPTION>
%while (my $ScripAction = $ScripActions->Next) {
<OPTION VALUE=<%$ScripAction->Id%>
-<% $ScripAction->Id == $Default && 'SELECTED' %>
+<% defined $Default && $ScripAction->Id == $Default && 'SELECTED' %>
><% loc($ScripAction->Name) %>
</OPTION>
%}
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripCondition
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripCondition (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Admin/Elements/SelectScripCondition Mon Mar 14 02:57:36 2005
@@ -45,11 +45,11 @@
%# END BPS TAGGED BLOCK }}}
<SELECT NAME=<%$Name%>>
<OPTION VALUE=""
-<% $Default eq undef && 'SELECTED' %>
+<% ! defined $Default && 'SELECTED' %>
>-</OPTION>
%while (my $ScripCondition = $ScripConditions->Next) {
<OPTION VALUE=<%$ScripCondition->Id%>
-<% $ScripCondition->Id == $Default && 'SELECTED' %>
+<% defined $Default && $ScripCondition->Id == $Default && 'SELECTED' %>
><% loc($ScripCondition->Name) %>
</OPTION>
%}
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Elements/Submit
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Elements/Submit (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Elements/Submit Mon Mar 14 02:57:36 2005
@@ -91,7 +91,7 @@
</TABLE>
<%ARGS>
$color => "#336699"
-$Caption => undef
+$Caption => ''
$AlternateCaption => undef
$AlternateLabel => undef
$Label => loc('Submit')
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Display.html
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Display.html (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Display.html Mon Mar 14 02:57:36 2005
@@ -124,10 +124,11 @@
}
}
- $ARGS{'UpdateContent'} =~ s/\r\n/\n/g;
+ $ARGS{'UpdateContent'} =~ s/\r\n/\n/g if defined $ARGS{'UpdateContent'};
if ( $ARGS{'UpdateTimeWorked'} ||
$session{'Attachments'} ||
- ( $ARGS{'UpdateContent'} ne ''
+ ( defined $ARGS{'UpdateContent'}
+ && $ARGS{'UpdateContent'} ne ''
&& $ARGS{'UpdateContent'} ne "-- \n"
. $session{'CurrentUser'}->UserObj->Signature )) {
$ARGS{UpdateAttachments} = $session{'Attachments'};
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowMessageStanza
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowMessageStanza (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowMessageStanza Mon Mar 14 02:57:36 2005
@@ -57,7 +57,7 @@
my $content = $stanza->{raw};
RT::Interface::Web::EscapeUTF8(\$content);
$m->comp('/Elements/Callback', content => \$content, %ARGS);
- $content =~ s/\n/<br>/gi;
+ $content =~ s/\n/<br>/gi if defined $content;
</%perl>
<%$content |n%><br>
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowTransaction
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowTransaction (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/ShowTransaction Mon Mar 14 02:57:36 2005
@@ -117,6 +117,7 @@
if ( $Ticket->Id != $Transaction->Ticket ) {
$TicketString = "Ticket " . $Transaction->Ticket . ": ";
}
+$TicketString ||= '';
if ( $Transaction->TimeTaken != 0 ) {
$TimeTaken = $Transaction->TimeTaken . " min";
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/Tabs
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/Tabs (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/html/Ticket/Elements/Tabs Mon Mar 14 02:57:36 2005
@@ -187,6 +187,7 @@
Order => $ARGS{'Order'} || $session{'CurrentSearchHash'}->{'Order'},
Rows => $ARGS{'Rows'},
) if ($ARGS{'Query'} or $session{'CurrentSearchHash'}->{'Query'});
+$args ||= '';
$tabs->{"f"} = { path => "Search/Build.html?NewQuery=1",
title => loc('New Search')};
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Action/CreateTickets.pm
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Action/CreateTickets.pm (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Action/CreateTickets.pm Mon Mar 14 02:57:36 2005
@@ -213,7 +213,7 @@
Fields marked with an * are required.
-Fields marked with a + man have multiple values, simply
+Fields marked with a + may have multiple values, simply
by repeating the fieldname on a new line with an additional value.
Fields marked with a ! are postponed to be processed after all
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Interface/Web.pm
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Interface/Web.pm (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Interface/Web.pm Mon Mar 14 02:57:36 2005
@@ -77,6 +77,7 @@
sub EscapeUTF8 {
my $ref = shift;
+ return unless defined $$ref;
my $val = $$ref;
use bytes;
$val =~ s/&/&/g;
Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Record.pm
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Record.pm (original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Record.pm Mon Mar 14 02:57:36 2005
@@ -1749,7 +1749,7 @@
# If we've been handed a value that contains at least one non-digit,
# it's a name. Resolve it into an id.
#
- if ( $field =~ /\D+/ ) {
+ if ( defined $field && $field =~ /\D+/ ) {
# Look up the field ID.
my $cfs = RT::CustomFields->new( $self->CurrentUser );
More information about the Rt-commit
mailing list