summaryrefslogtreecommitdiff
path: root/rt/html/Elements/EditCustomField
diff options
context:
space:
mode:
authorivan <ivan>2008-03-02 04:06:06 +0000
committerivan <ivan>2008-03-02 04:06:06 +0000
commit9c68254528b6f2c7d8c1921b452fa56064783782 (patch)
tree09623ba39355e74f1cff2f3c35b7347bd309f306 /rt/html/Elements/EditCustomField
parentef20b2b6b1feb47ad02b5ff7525f1a0fd11d0fa4 (diff)
import rt 3.4.6
Diffstat (limited to 'rt/html/Elements/EditCustomField')
-rw-r--r--rt/html/Elements/EditCustomField16
1 files changed, 5 insertions, 11 deletions
diff --git a/rt/html/Elements/EditCustomField b/rt/html/Elements/EditCustomField
index d247c63..e443c76 100644
--- a/rt/html/Elements/EditCustomField
+++ b/rt/html/Elements/EditCustomField
@@ -2,7 +2,7 @@
%#
%# COPYRIGHT:
%#
-%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC
%# <jesse@bestpractical.com>
%#
%# (Except where explicitly superseded by other copyright notices)
@@ -22,9 +22,7 @@
%#
%# You should have received a copy of the GNU General Public License
%# along with this program; if not, write to the Free Software
-%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-%# 02110-1301 or visit their web page on the internet at
-%# http://www.gnu.org/copyleft/gpl.html.
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
%#
%#
%# CONTRIBUTION SUBMISSION POLICY:
@@ -47,7 +45,7 @@
%# END BPS TAGGED BLOCK }}}
<%INIT>
my $Values;
-if ($Object and $Object->id) {
+if ($Object) {
$Values = $Object->CustomFieldValues($CustomField->id);
$Values->Columns( qw( id CustomField ObjectType ObjectId Disabled Content ContentType ContentEncoding ) );
$NamePrefix ||= join('-', 'Object', ref($Object), $Object->Id, 'CustomField', '');
@@ -69,14 +67,10 @@ if ($MaxValues == 1 and $Object and $Values) {
}
# The "Magic" hidden input causes RT to know 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("\n".'<input type="hidden" class="hidden" name="'.$NamePrefix.$CustomField->Id.'-Values-Magic" value="1" />'."\n");
-
-my $EditComponent = "EditCustomField$Type";
-$m->comp('/Elements/Callback', _CallbackName => 'EditComponentName', Name => \$EditComponent, CustomField => $CustomField, Object => $Object );
-$EditComponent = "EditCustomField$Type" unless $m->comp_exists($EditComponent);
+$m->out("\n".'<input type="hidden" name="'.$NamePrefix.$CustomField->Id.'-Values-Magic" value="1">'."\n");
return $m->comp(
- $EditComponent,
+ "EditCustomField$Type",
%ARGS,
Rows => $Rows,
Cols => $Cols,