X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=rt%2Flib%2FRT%2FCustomField.pm;h=8d16c1fe12a57ff8ada4de3f61729b9978b631fe;hb=54a357b171aa44f9399b4c146acd2afd3b686075;hp=7ba24b8beaf90cfa845e799fd3d2a63e571410e4;hpb=85e677b86fc37c54e6de2b06340351a28f5a5916;p=freeside.git diff --git a/rt/lib/RT/CustomField.pm b/rt/lib/RT/CustomField.pm index 7ba24b8be..8d16c1fe1 100644 --- a/rt/lib/RT/CustomField.pm +++ b/rt/lib/RT/CustomField.pm @@ -410,6 +410,10 @@ sub Create { $self->SetUILocation( $args{'UILocation'} ); } + if ( exists $args{'NoClone'} ) { + $self->SetNoClone( $args{'NoClone'} ); + } + return ($rv, $msg) unless exists $args{'Queue'}; # Compat code -- create a new ObjectCustomField mapping @@ -1822,9 +1826,20 @@ sub SetUILocation { } } +sub NoClone { + my $self = shift; + $self->FirstAttribute('NoClone') ? 1 : ''; +} - - +sub SetNoClone { + my $self = shift; + my $value = shift; + if ( $value ) { + return $self->SetAttribute( Name => 'NoClone', Content => 1 ); + } else { + return $self->DeleteAttribute('NoClone'); + } +} =head2 id