--- loncom/html/adm/helper/newslot.helper 2006/04/24 23:23:18 1.15 +++ loncom/html/adm/helper/newslot.helper 2008/12/21 16:51:28 1.24 @@ -1,5 +1,6 @@ - + OPTIONAL @@ -30,7 +31,7 @@ } - Name:
    +
Name:
   
@@ -84,7 +85,8 @@
- +

Description:
    @@ -110,7 +112,7 @@ -

Maxium number of students allowed in this slot:
    +

Maximum number of students allowed in this slot:
    @@ -157,6 +159,20 @@ delete($helper->{'VARS'}{'endunique'}); + + +

Proctored access: + + + No proctor checkin required for access. + Require proctored checkin for access. + + my $default=&{$helper->{DATA}{origslot}}('proctor'); + if ($default) { return 'yes'; } + return 'no'; + + +

Secret word proctors use to checkin users:
    @@ -171,6 +187,8 @@

Slot is: + + usable for any resource. restricted to a specific resource. @@ -180,6 +198,7 @@ return 'any'; +

IP restrictions:
    @@ -209,22 +228,22 @@ - + - FINISH + + $helper->{'VARS'}{'useproctor'} eq 'no' + RESTRICTUSER + - - $helper->{'VARS'}{'type'} eq 'schedulable_student' - RESTRICTUSER - + RESTRICTUSER + activeonly="1" emptyallowed="0"> my @defaults; my $default=&{$helper->{DATA}{origslot}}('proctor'); if ($default) { - $default=~ tr/@/:/; @defaults=(split(',',$default)); } return @defaults; @@ -233,7 +252,13 @@ - + + + $helper->{'VARS'}{'type'} ne 'schedulable_student' + FINISH + + FINISH

Slots are by default available to all users in a course, if you would like this slot to be restricted to a subset of users you can specify restrictions.

@@ -288,13 +313,16 @@ $helper->{'VARS'}{'endunique'}]; } - if ( $helper->{'VARS'}{'proctor'} =~/\S/ ) { + if ( $helper->{'VARS'}{'useproctor'} eq 'yes' + && $helper->{'VARS'}{'proctor'} =~/\S/ ) { my @names; + # just need the username/domain throw away the other data + # that returns foreach my $user (split(/\|\|\|/, $helper->{'VARS'}{'proctor'})) { my ($uname,$udomain)=split(/:/,$user); - push(@names,"$uname\@$udomain"); + push(@names,"$uname:$udomain"); } - # make sure the usenrmaes are unique + # make sure the usernmaes are unique my %proctors = map { ($_,1) } @names; $slot{'proctor'}=join(',',sort(keys(%proctors))); } @@ -306,8 +334,9 @@ } if ( $helper->{'VARS'}{'allowedusers'} =~/\S/ ) { - my @names; + # just need the username/domain throw away the other data + # that returns foreach my $item (split(/\|\|\|/, $helper->{'VARS'}{'allowedusers'})) { my ($uname,$udomain)=split(/:/,$item);