[Rt-commit] rt branch, 4.2/consistent-cf-name-localization, created. rt-4.2.1-3-gf7d9b0d
? sunnavy
sunnavy at bestpractical.com
Mon Nov 25 11:36:55 EST 2013
The branch, 4.2/consistent-cf-name-localization has been created
at f7d9b0d1f2d178bafcd8ee292ab461beb3127e9d (commit)
- Log -----------------------------------------------------------------
commit f7d9b0d1f2d178bafcd8ee292ab461beb3127e9d
Author: sunnavy <sunnavy at bestpractical.com>
Date: Thu Nov 21 00:21:46 2013 +0800
stop localizing custom field names
for consistency: we don't localize them in all of the places.
we might support cf name localization in the future though.
there is also a cf loc bug, see #27169
this commit actually also reverts ce24f2a(essentially)
diff --git a/lib/RT/Report/Tickets.pm b/lib/RT/Report/Tickets.pm
index 3fc4c64..43cfa2a 100644
--- a/lib/RT/Report/Tickets.pm
+++ b/lib/RT/Report/Tickets.pm
@@ -183,7 +183,7 @@ our %GROUPINGS_META = (
$cf = $obj->Name;
}
- return 'Custom field [_1]', $self->CurrentUser->loc( $cf );
+ return 'Custom field [_1]', $cf;
},
},
Enum => {
diff --git a/share/html/Admin/Groups/Modify.html b/share/html/Admin/Groups/Modify.html
index e9c404c..3043fe8 100644
--- a/share/html/Admin/Groups/Modify.html
+++ b/share/html/Admin/Groups/Modify.html
@@ -72,7 +72,7 @@
% my $CFs = $Group->CustomFields;
% while (my $CF = $CFs->Next) {
<tr valign="top"><td align="right">
-<% loc($CF->Name) %>:
+<% $CF->Name %>:
</td><td>
<& /Elements/EditCustomField, CustomField => $CF,
Object => $Group, &>
diff --git a/share/html/Admin/Queues/Modify.html b/share/html/Admin/Queues/Modify.html
index 5e20e27..162201f 100644
--- a/share/html/Admin/Queues/Modify.html
+++ b/share/html/Admin/Queues/Modify.html
@@ -104,7 +104,7 @@
% my $CFs = $QueueObj->CustomFields;
% while (my $CF = $CFs->Next) {
<tr valign="top"><td align="right">
-<% loc($CF->Name) %>:
+<% $CF->Name %>:
</td><td>
<& /Elements/EditCustomField, CustomField => $CF,
Object => $QueueObj, &>
diff --git a/share/html/Elements/BulkCustomFields b/share/html/Elements/BulkCustomFields
index b1f54cc..329e4b0 100644
--- a/share/html/Elements/BulkCustomFields
+++ b/share/html/Elements/BulkCustomFields
@@ -55,7 +55,7 @@
% my $i = 0;
% while (my $cf = $CustomFields->Next) {
<tr class="<% ++$i%2 ? 'oddline': 'evenline' %>">
-<td class="label"><% loc($cf->Name) %><br />
+<td class="label"><% $cf->Name %><br />
<em>(<% $cf->FriendlyType %>)</em></td>
% my $rows = 5;
% my $cf_id = $cf->id;
@@ -91,4 +91,4 @@ $CustomFields
</%ARGS>
<%INIT>
return unless $CustomFields->Count;
-</%INIT>
\ No newline at end of file
+</%INIT>
diff --git a/share/html/Elements/EditCustomFields b/share/html/Elements/EditCustomFields
index c4bb95a..f91c4cb 100644
--- a/share/html/Elements/EditCustomFields
+++ b/share/html/Elements/EditCustomFields
@@ -56,7 +56,7 @@
<<% $FIELD %> class="edit-custom-field cftype-<% $Type %>">
<<% $CELL %> class="cflabel">
- <span class="name"><% loc($CustomField->Name) %>:</span><br />
+ <span class="name"><% $CustomField->Name %>:</span><br />
<span class="type"><% $CustomField->FriendlyType %></span>
</<% $CELL %>>
<<% $CELL %> class="entry">
diff --git a/share/html/Elements/ValidateCustomFields b/share/html/Elements/ValidateCustomFields
index ae63fbf..79c619b 100644
--- a/share/html/Elements/ValidateCustomFields
+++ b/share/html/Elements/ValidateCustomFields
@@ -85,7 +85,7 @@ while ( my $CF = $CustomFields->Next ) {
my $msg =
loc( "Input can not be parsed as an IP address" );
$m->notes( ( 'InvalidField-' . $CF->Id ) => $msg );
- push @res, loc($CF->Name) .': '. $msg;
+ push @res, $CF->Name .': '. $msg;
$valid = 0;
}
}
@@ -96,7 +96,7 @@ while ( my $CF = $CustomFields->Next ) {
my $msg =
loc( "Input can not be parsed as an IP address range" );
$m->notes( ( 'InvalidField-' . $CF->Id ) => $msg );
- push @res, loc($CF->Name) .': '. $msg;
+ push @res, $CF->Name .': '. $msg;
$valid = 0;
}
}
@@ -106,7 +106,7 @@ while ( my $CF = $CustomFields->Next ) {
my $msg = loc("Input must match [_1]", $CF->FriendlyPattern);
$m->notes( ('InvalidField-' . $CF->Id) => $msg );
- push @res, loc($CF->Name) .': '. $msg;
+ push @res, $CF->Name .': '. $msg;
$valid = 0;
}
}
diff --git a/share/html/Ticket/Elements/EditTransactionCustomFields b/share/html/Ticket/Elements/EditTransactionCustomFields
index 04eaded..8cef77e 100644
--- a/share/html/Ticket/Elements/EditTransactionCustomFields
+++ b/share/html/Ticket/Elements/EditTransactionCustomFields
@@ -54,7 +54,7 @@
% next unless $CF->CurrentUserHasRight('ModifyCustomField');
<<% $FIELD %>>
<<% $CELL %> class="label cflabel">
- <span class="name"><% loc($CF->Name) %>:</span><br />
+ <span class="name"><% $CF->Name %>:</span><br />
<span class="type"><% $CF->FriendlyType %></span>
</<% $CELL %>>
<<% $CELL %>>
-----------------------------------------------------------------------
More information about the rt-commit
mailing list