--- loncom/enrollment/localenroll.pm 2021/06/15 20:52:27 1.61 +++ loncom/enrollment/localenroll.pm 2022/01/14 16:27:20 1.63 @@ -1,6 +1,6 @@ # functions to glue school database system into Lon-CAPA for # automated enrollment -# $Id: localenroll.pm,v 1.61 2021/06/15 20:52:27 raeburn Exp $ +# $Id: localenroll.pm,v 1.63 2022/01/14 16:27:20 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -731,7 +731,7 @@ sub check_instclasses { =cut sub instsec_reformat { - my ($dom,$action,$instsecref) = @; + my ($dom,$action,$instsecref) = @_; if ((ref($instsecref) eq 'HASH') && (($action eq 'clutter') || ($action eq 'declutter'))) { foreach my $key (keys(%{$instsecref})) { @@ -1072,6 +1072,13 @@ sub instcode_defaults { (d) $lc_users - reference to hash containing LON-CAPA usernames in in domain $dom, as keys. Needed if institutional data source only allows query by username. + (e) $counts - reference to hash (optional), for use when called + from Autoupdate.pl which can contain counts for + user-specified items retrieved in allusers_info() + or in custom subroutines which it calls. Key in + hashref, and count value will be printed to + autoupdate.log by Autoupdate.pl. + returns 1 parameter - 'ok' if no processing error, or other value if an error occurred. side effects - populates the $instusers and $instids refs to hashes. @@ -1082,7 +1089,7 @@ sub instcode_defaults { =cut sub allusers_info { - my ($dom,$instusers,$instids,$lc_users) = @_; + my ($dom,$instusers,$instids,$lc_users,$counts) = @_; my $outcome = 'ok'; return $outcome; }