|
Lines 682-694
set_userenv is called in Auth.pm
Link Here
|
| 682 |
=cut |
682 |
=cut |
| 683 |
|
683 |
|
| 684 |
#' |
684 |
#' |
|
|
685 |
sub set_userenv_from_session { |
| 686 |
my ( $class, $session ) = @_; |
| 687 |
return $class->set_userenv( |
| 688 |
$session->param('number'), $session->param('id') // '', |
| 689 |
$session->param('cardnumber'), $session->param('firstname'), |
| 690 |
$session->param('surname'), $session->param('branch'), |
| 691 |
$session->param('branchname'), $session->param('flags'), |
| 692 |
$session->param('emailaddress'), $session->param('shibboleth'), |
| 693 |
$session->param('desk_id'), $session->param('desk_name'), |
| 694 |
$session->param('register_id'), $session->param('register_name'), |
| 695 |
$session->id, |
| 696 |
); |
| 697 |
} |
| 685 |
sub set_userenv { |
698 |
sub set_userenv { |
| 686 |
shift @_; |
699 |
shift @_; |
| 687 |
my ( |
700 |
my ( |
| 688 |
$usernum, $userid, $usercnum, $userfirstname, |
701 |
$usernum, $userid, $usercnum, $userfirstname, |
| 689 |
$usersurname, $userbranch, $branchname, $userflags, |
702 |
$usersurname, $userbranch, $branchname, $userflags, |
| 690 |
$emailaddress, $shibboleth, $desk_id, $desk_name, |
703 |
$emailaddress, $shibboleth, $desk_id, $desk_name, |
| 691 |
$register_id, $register_name |
704 |
$register_id, $register_name, $session_id, |
| 692 |
) = @_; |
705 |
) = @_; |
| 693 |
|
706 |
|
| 694 |
my $cell = { |
707 |
my $cell = { |
|
Lines 707-713
sub set_userenv {
Link Here
|
| 707 |
"desk_id" => $desk_id, |
720 |
"desk_id" => $desk_id, |
| 708 |
"desk_name" => $desk_name, |
721 |
"desk_name" => $desk_name, |
| 709 |
"register_id" => $register_id, |
722 |
"register_id" => $register_id, |
| 710 |
"register_name" => $register_name |
723 |
"register_name" => $register_name, |
|
|
724 |
"session_id" => $session_id, |
| 711 |
}; |
725 |
}; |
| 712 |
$context->{userenv} = $cell; |
726 |
$context->{userenv} = $cell; |
| 713 |
return $cell; |
727 |
return $cell; |