[rt-users] rt2-to-rt3-v1.6: importing users without EmailAddress

Jesse Vincent jesse at bestpractical.com
Wed Mar 26 11:31:28 EST 2003


So. you might want to have a look at the recently release 1.7 version of
the import tool. And if you're going to hack on these things, you should
really subscribe to rt-devel where they're more likely to get discussed
;)

	-jesse


On Wed, Mar 26, 2003 at 02:20:06PM +0000, Carlos Canau wrote:
> Hi,
> 
> v1.6 doesn't  import users that  doesn't have EmailAddress. I  open my
> users       without       EmailAddress.       Can       I       change
> load_user($user->{'EmailAddress'}    with    load_user($user->{'Name'}
> safely ?? It seems to work.
> 
> </canau
> 
> 
> --- dumpfile-to-rt-3.0~ Wed Mar 26 11:30:04 2003
> +++ dumpfile-to-rt-3.0  Wed Mar 26 14:10:38 2003
> @@ -598,6 +598,7 @@
>  sub import_user {
>          my $user = shift;
>  
> +       printf "%s\n", scalar Dumper $user;
>          $user->{'Name'} = "Unnamed user ".$user->{'id'} unless ($user->{'Name'});
>          if ( $user->{'Name'} eq 'Nobody' ) {
>              $user_map->{ $user->{'id'} } = $RT::Nobody->Id;
> @@ -617,7 +618,8 @@
>            unless ( $user->{'Password'} =~ '^\*' );
>          delete $user->{'Password'};
>          print ".";
> -        $user_obj = load_user($user->{'EmailAddress'});
> +###        $user_obj = load_user($user->{'EmailAddress'});
> +        $user_obj = load_user($user->{'Name'});
>          unless ($user_obj->Id) {
>          my ($uid, $umsg) = $user_obj->Create( %{$user} );
>          }
> _______________________________________________
> rt-users mailing list
> rt-users at lists.fsck.com
> http://lists.fsck.com/mailman/listinfo/rt-users
> 
> Have you read the FAQ? The RT FAQ Manager lives at http://fsck.com/rtfm

-- 
http://www.bestpractical.com/rt  -- Trouble Ticketing. Free.



More information about the rt-users mailing list