From f32dca7aa15de7476d8ed0e654ad89ae9c30d181 Mon Sep 17 00:00:00 2001 From: Jason Etheridge Date: Wed, 4 Apr 2012 10:38:53 -0400 Subject: [PATCH] perl modules from asp-tadl-app1, minus OpenILS/SIP/Patron.pm --- Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm | 6 ++++-- Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/CDBI/actor.pm | 2 +- Open-ILS/src/perlmods/lib/OpenILS/WWW/Redirect.pm | 2 ++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm index 8b56e9757a..9140233b8b 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm @@ -775,6 +775,7 @@ sub _add_update_cards { my $session = shift; my $patron = shift; my $new_patron = shift; + my $user = shift; my $evt; @@ -786,7 +787,7 @@ sub _add_update_cards { if(ref($card) and $card->isnew()) { $virtual_id = $card->id(); - ( $card, $evt ) = _add_card($session,$card); + ( $card, $evt ) = _add_card($session,$card,$user); return (undef, $evt) if $evt; #if(ref($patron->card)) { $patron->card($patron->card->id); } @@ -807,8 +808,9 @@ sub _add_update_cards { # adds an card to the db and returns the card with new id sub _add_card { - my( $session, $card ) = @_; + my( $session, $card, $user ) = @_; $card->clear_id(); + $card->creator($user->id); $logger->info("Adding new patron card ".$card->barcode); diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/CDBI/actor.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/CDBI/actor.pm index 392febe999..cbcbf9a3ad 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/CDBI/actor.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/CDBI/actor.pm @@ -142,7 +142,7 @@ use base qw/actor/; __PACKAGE__->table( 'actor_card' ); __PACKAGE__->columns( Primary => qw/id/ ); -__PACKAGE__->columns( Essential => qw/usr barcode active/ ); +__PACKAGE__->columns( Essential => qw/usr barcode active creator create_date/ ); #------------------------------------------------------------------------------- package actor::user_access_entry; diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Redirect.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Redirect.pm index c76cbf3706..ba777ef33a 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Redirect.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Redirect.pm @@ -74,6 +74,8 @@ sub handler { $logger->debug("Apache client connecting from $user_ip"); my ($shortname, $nskin, $nhostname) = redirect_libs($user_ip); + $url .= "?ol=" . 22; + $url .= "&d=$depth" if defined $depth; if ($shortname) { if ($nskin =~ m/[^\s]/) { $skin = $nskin; } -- 2.11.0