version 1.503, 2004/05/27 04:25:12
|
version 1.504, 2004/05/27 22:25:16
|
Line 1638 sub courseiddump {
|
Line 1638 sub courseiddump {
|
# |
# |
# ----------------------------------------------------------- Check out an item |
# ----------------------------------------------------------- Check out an item |
|
|
|
sub get_first_access { |
|
my ($type,$argsymb)=@_; |
|
my ($symb,$courseid,$udom,$uname)=&Apache::lonxml::whichuser(); |
|
if ($argsymb) { $symb=$argsymb; } |
|
my ($map,$id,$res)=&decode_symb($symb); |
|
if ($type eq 'map') { $res=$map; } |
|
my %times=&get('firstaccesstimes',[$res],$udom,$uname); |
|
return $times{$res}; |
|
} |
|
|
|
sub set_first_access { |
|
my ($type)=@_; |
|
my ($symb,$courseid,$udom,$uname)=&Apache::lonxml::whichuser(); |
|
my ($map,$id,$res)=&decode_symb($symb); |
|
if ($type eq 'map') { $res=$map; } |
|
return &put('firstaccesstimes',{$res=>time},$udom,$uname); |
|
} |
|
|
sub checkout { |
sub checkout { |
my ($symb,$tuname,$tudom,$tcrsid)=@_; |
my ($symb,$tuname,$tudom,$tcrsid)=@_; |
my $now=time; |
my $now=time; |