[Rt-commit] [svn] r1916 - in rt/branches/3.3-TESTING: .
html/Elements html/Search html/Ticket html/Ticket/Elements
jesse at pallas.eruditorum.org
jesse at pallas.eruditorum.org
Thu Nov 18 11:00:19 EST 2004
Author: jesse
Date: Thu Nov 18 11:00:17 2004
New Revision: 1916
Modified:
rt/branches/3.3-TESTING/ (props changed)
rt/branches/3.3-TESTING/html/Elements/EditCustomField
rt/branches/3.3-TESTING/html/Search/Bulk.html
rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomField
rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomFields
rt/branches/3.3-TESTING/html/Ticket/Elements/Tabs
rt/branches/3.3-TESTING/html/Ticket/ModifyAll.html
Log:
r9296 at tinbook: jesse | 2004-11-18T15:59:55.061638Z
Ported Custom Field editing fixes from 3.2. Added a deprecated warning to a deprecated API.
Cleaned up a tiny bit of formatting
Modified: rt/branches/3.3-TESTING/html/Elements/EditCustomField
==============================================================================
--- rt/branches/3.3-TESTING/html/Elements/EditCustomField (original)
+++ rt/branches/3.3-TESTING/html/Elements/EditCustomField Thu Nov 18 11:00:17 2004
@@ -56,6 +56,11 @@
$Default = ($Values->First ? $Values->First->Content : '');
$Values->GotoFirstItem;
}
+
+# The "Magic" hidden input causes RT to knowi that we were trying to edit the field, even if
+# we don't see a value later, since browsers aren't compelled to submit empty form fields
+$m->out('<input type="hidden" name="'.$NamePrefix.$CustomField->Id.'-Values-Magic" value="1">');
+
return $m->comp(
"EditCustomField$Type",
%ARGS,
Modified: rt/branches/3.3-TESTING/html/Search/Bulk.html
==============================================================================
--- rt/branches/3.3-TESTING/html/Search/Bulk.html (original)
+++ rt/branches/3.3-TESTING/html/Search/Bulk.html Thu Nov 18 11:00:17 2004
@@ -155,7 +155,10 @@
% while (my $CF = $TxnCFs->Next()) {
<TR>
<TD ALIGN=RIGHT><% $CF->Name %>:</TD>
-<TD><& /Elements/EditCustomField, CustomField => $CF, NamePrefix => "Object-RT::Transaction--CustomField-" &><em><% $CF->FriendlyType %></em></TD>
+<TD><& /Elements/EditCustomField,
+ CustomField => $CF,
+ NamePrefix => "Object-RT::Transaction--CustomField-"
+ &><em><% $CF->FriendlyType %></em></TD>
</TD></TR>
% } # end if while
<tr><td align=right><&|/l&>Attach</&>:</td><td><input name="UpdateAttachment" type="file"></td></tr>
@@ -165,35 +168,6 @@
</table>
<& /Elements/TitleBoxEnd &>
-% if (0) {
-<table>
-% foreach (keys %allcfs) {
-<tr><td class=label>
-% my $cf = $allcfs{$_};
-% my $pref;
-% if ($cf->Queue == 0) {
-% $pref = "[Global]";
-% } else {
-% $pref = "[Queue: " . $cfqnames{$_} . "]";
-% }
-<%$pref%> <b><% $cf->Name %></b><br>
-<% $cf->FriendlyType %>
-</td>
-<td>
-% if ($cf->Type ne "FreeformMultiple") {
-<& /Ticket/Elements/EditCustomField, CustomField => $cf &>
-% } else {
-Add Values<br>
-<textarea cols=15 rows=3 name="<%$cf->Id%>-Values"></textarea>
-</td><td>
-Delete Values<br>
-<textarea cols=15 rows=3 name="<%$cf->Id%>-DeleteValues"></textarea>
-% }
-</td>
-</tr>
-% }
-</table>
-% }
<& /Elements/TitleBoxStart, title => loc('Edit Links'), color => "#336633"&>
Modified: rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomField
==============================================================================
--- rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomField (original)
+++ rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomField Thu Nov 18 11:00:17 2004
@@ -93,3 +93,7 @@
$Cols=> 15
$Default => undef
</%ARGS>
+<%init>
+use Carp;
+$RT::Logger->error("Ticket/Elements/EditCustomField is deprecated in RT 3.4 and will be removed.\n". Carp::longmess);
+</%init>
Modified: rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomFields
==============================================================================
--- rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomFields (original)
+++ rt/branches/3.3-TESTING/html/Ticket/Elements/EditCustomFields Thu Nov 18 11:00:17 2004
@@ -66,7 +66,11 @@
<b><%$CustomField->Name%></b><br>
<i><%$CustomField->FriendlyType%></i>
</td>
- <td class="entry"><& /Elements/EditCustomField, Object => $TicketObj, CustomField => $CustomField, NamePrefix => $NamePrefix &></td>
+ <td class="entry"><& /Elements/EditCustomField,
+ Object => $TicketObj,
+ CustomField => $CustomField,
+ NamePrefix => $NamePrefix
+ &></td>
</tr>
% }
</table>
Modified: rt/branches/3.3-TESTING/html/Ticket/Elements/Tabs
==============================================================================
--- rt/branches/3.3-TESTING/html/Ticket/Elements/Tabs (original)
+++ rt/branches/3.3-TESTING/html/Ticket/Elements/Tabs Thu Nov 18 11:00:17 2004
@@ -211,7 +211,7 @@
<%ARGS>
$Ticket => undef
$subtabs => undef
-$current_tab => undef
-$current_subtab => undef
+$current_tab => ''
+$current_subtab => ''
$Title => undef
</%ARGS>
Modified: rt/branches/3.3-TESTING/html/Ticket/ModifyAll.html
==============================================================================
--- rt/branches/3.3-TESTING/html/Ticket/ModifyAll.html (original)
+++ rt/branches/3.3-TESTING/html/Ticket/ModifyAll.html Thu Nov 18 11:00:17 2004
@@ -104,7 +104,10 @@
% while (my $CF = $TxnCFs->Next()) {
<TR>
<TD class="label"><% $CF->Name %>:</TD>
-<TD class="entry"><& /Elements/EditCustomField, CustomField => $CF, NamePrefix => "Object-RT::Transaction--CustomField-" &><em><% $CF->FriendlyType %></em></TD>
+<TD class="entry"><& /Elements/EditCustomField,
+ CustomField => $CF,
+ NamePrefix => "Object-RT::Transaction--CustomField-"
+ &><em><% $CF->FriendlyType %></em></TD>
</TD></TR>
% } # end if while
% } # end of if
@@ -120,7 +123,9 @@
<& /Elements/TitleBoxEnd &>
-<& /Elements/Submit, Label => loc('Save Changes'), Caption => loc("If you've updated anything above, be sure to"), color => "#333399" &>
+<& /Elements/Submit,
+ Label => loc('Save Changes'),
+ Caption => loc("If you've updated anything above, be sure to"), color => "#333399" &>
</form>
<%INIT>
More information about the Rt-commit
mailing list