--- loncom/enrollment/localenroll.pm 2013/03/01 04:49:04 1.44 +++ loncom/enrollment/localenroll.pm 2014/01/03 18:39:55 1.45 @@ -1,6 +1,6 @@ # functions to glue school database system into Lon-CAPA for # automated enrollment -# $Id: localenroll.pm,v 1.44 2013/03/01 04:49:04 raeburn Exp $ +# $Id: localenroll.pm,v 1.45 2014/01/03 18:39:55 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -437,6 +437,39 @@ sub crsreq_checks { return 'ok'; } +sub crsreq_updates { + my ($cdom,$cnum,$crstype,$action,$ownername,$ownerdomain,$fullname,$title, + $code,$incoming,$outgoing) = @_; + unless (ref($outgoing) eq 'HASH') { + return 'fail'; + } + my %extrainfo; + if (ref($incoming) eq 'HASH') { + %extrainfo = %{$incoming}; + } + if ($action eq 'review') { + $outgoing->{'reviewweb'} = ''; + } elsif ($action eq 'process') { + $outgoing->{'formitems'} = {}; # key=>value, where key is form element name + # and value is multiple, if there + # are multiple form elements with + # the same name. + } elsif ($action eq 'created') { + $outgoing->{'createdweb'} = ''; + $outgoing->{'createdmsg'} = [{ + mt => '', + args => [], + }]; + } elsif ($action eq 'queued') { + $outgoing->{'queuedmsg'} = [{ + mt => '', + args => [], + }]; + $outgoing->{'queuedweb'} = ''; + } + return 'ok' +} + =pod =item create_password()