--- loncom/interface/loncreateuser.pm 2010/04/14 13:58:11 1.340 +++ loncom/interface/loncreateuser.pm 2010/05/22 01:27:48 1.343 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Create a user # -# $Id: loncreateuser.pm,v 1.340 2010/04/14 13:58:11 wenzelju Exp $ +# $Id: loncreateuser.pm,v 1.343 2010/05/22 01:27:48 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2385,15 +2385,17 @@ sub update_user_data { } } foreach my $item (@requestcourses) { - $newcustom{$item} = $env{'form.crsreq_'.$item}; - if ($env{'form.crsreq_'.$item} eq 'autolimit') { - $newcustom{$item} .= '='; - unless ($env{'form.crsreq_'.$item.'_limit'} =~ /\D/) { - $newcustom{$item} .= $env{'form.crsreq_'.$item.'_limit'}; + if ($env{'form.custom'.$item} == 1) { + $newcustom{$item} = $env{'form.crsreq_'.$item}; + if ($env{'form.crsreq_'.$item} eq 'autolimit') { + $newcustom{$item} .= '='; + unless ($env{'form.crsreq_'.$item.'_limit'} =~ /\D/) { + $newcustom{$item} .= $env{'form.crsreq_'.$item.'_limit'}; + } } + $changed{$item} = &tool_admin($item,$newcustom{$item}, + \%changeHash,'requestcourses'); } - $changed{$item} = &tool_admin($item,$newcustom{$item}, - \%changeHash,'requestcourses'); } } if ($canmodify_status{'inststatus'}) { @@ -2437,7 +2439,7 @@ sub update_user_data { } } ## - my (@userroles,%userupdate,$cnum,$cdom,$crstype,%namechanged); + my (@userroles,%userupdate,$cnum,$cdom,%namechanged); if ($context eq 'course') { ($cnum,$cdom) = &Apache::lonuserutils::get_course_identity(); $crstype = &Apache::loncommon::course_type($cdom.'_'.$cnum); @@ -4526,7 +4528,7 @@ sub print_main_menu { push(@{ $menu[2]->{items} }, { linktext => 'User Self-Enrollment', - icon => 'cstr.png', + icon => 'self_enroll.png', #help => 'Course_Self_Enrollment', url => '/adm/createuser?action=selfenroll', permission => $permission->{'cusr'}, @@ -4952,7 +4954,7 @@ ENDSCRIPT ''. &Apache::loncommon::plainname($ccuname,$ccudom). ''; - $count; + $count ++; } my $rem = $count%$numcols; if ($rem) { @@ -4969,7 +4971,7 @@ ENDSCRIPT my $cid = $env{'request.course.id'}; my $currlim = $env{'course.'.$cid.'.internal.selfenroll_limit'}; my $currcap = $env{'course.'.$cid.'.internal.selfenroll_cap'}; - my $nolimit = ' checked="checked" '; + $nolimit = ' checked="checked" '; if ($currlim eq 'allstudents') { $crslimit = ' checked="checked" '; $selflimit = ' ';