--- loncom/interface/Attic/londropadd.pm 2007/09/27 18:58:52 1.170 +++ loncom/interface/Attic/londropadd.pm 2007/10/09 17:33:57 1.171 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler to drop and add students in courses # -# $Id: londropadd.pm,v 1.170 2007/09/27 18:58:52 www Exp $ +# $Id: londropadd.pm,v 1.171 2007/10/09 17:33:57 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -262,8 +262,9 @@ sub print_upload_manager_header { $password_choice = 'int'; } # - my $javascript_validations=&javascript_validations('auth',$krbdefdom, - $password_choice); + my $javascript_validations = + &javascript_validations('auth',$krbdefdom,$password_choice,undef, + $env{'request.role.domain'}); my $checked=(($env{'form.noFirstLine'})?' checked="checked" ':''); $r->print('

'.&mt('Uploading Class List')."

\n". "
\n". @@ -293,7 +294,7 @@ sub print_upload_manager_header { ############################################################### ############################################################### sub javascript_validations { - my ($mode,$krbdefdom,$curr_authtype,$curr_authfield)=@_; + my ($mode,$krbdefdom,$curr_authtype,$curr_authfield,$domain)=@_; my $authheader; if ($mode eq 'auth') { my %param = ( formname => 'studentform', @@ -302,7 +303,7 @@ sub javascript_validations { $authheader = &Apache::loncommon::authform_header(%param); } elsif ($mode eq 'createcourse') { my %param = ( formname => 'ccrs', - kerb_def_dom => $krbdefdom, + kerb_def_dom => $krbdefdom, curr_authtype => $curr_authtype ); $authheader = &Apache::loncommon::authform_header(%param); } elsif ($mode eq 'modifycourse') { @@ -331,6 +332,7 @@ sub javascript_validations { my $function_name =(< 1) { + $auth_checks .= (< "Personal Data", 'fn' => "First Name", 'mn' => "Middle Name", 'ln' => "Last Name", 'gen' => "Generation", 'hs' => "Home Server", - 'pswd' => "Password", + 'pswd' => "Login Data", 'psam' => "Please select an authentication mechanism", 'mail' => "Email Address" ); @@ -1109,15 +1117,18 @@ sub print_enroll_single_student_form {

$lt{'pswd'}

$lt{'psam'}$authhelp -

-$krbform -
-$intform -
-$locform -

END + if ($krbform ne '') { + $user_data_html .= $krbform.'
'; + } + if ($intform ne '') { + $user_data_html .= $intform.'
'; + } + if ($locform ne '') { + $user_data_html .= $locform.'
'; + } + $user_data_html .= "\n

\n" } else { # User already exists. Do not worry about authentication my %uenv = &Apache::lonnet::dump('environment',$ccdomain,$ccuname); @@ -2754,6 +2765,9 @@ sub handler { if ($env{'form.phase'} eq 'get_user_info') { my ($currstate,$response,$forcenewuser,$results) = &Apache::loncreateuser::user_search_result($srch); + if ($env{'form.currstate'} eq 'modify') { + $currstate = $env{'form.currstate'}; + } if ($currstate eq 'select') { $r->print(&header()); &Apache::lonhtmlcommon::add_breadcrumb