From: erickson Date: Wed, 27 Jul 2005 20:59:35 +0000 (+0000) Subject: added staff call to modsize stuff X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=1049b54276ea50ebef782684cbc72af8c97f252e;p=Evergreen.git added staff call to modsize stuff git-svn-id: svn://svn.open-ils.org/ILS/trunk@1554 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm b/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm index e01d9a9e58..e0b4920a61 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm @@ -747,6 +747,10 @@ __PACKAGE__->register_method( method => "biblio_mrid_to_modsbatch", api_name => "open-ils.search.biblio.metarecord.mods_slim.retrieve"); +__PACKAGE__->register_method( + method => "biblio_mrid_to_modsbatch", + api_name => "open-ils.search.biblio.metarecord.mods_slim.retrieve.staff"); + sub biblio_mrid_to_modsbatch { my( $self, $client, $mrid ) = @_; @@ -775,7 +779,12 @@ sub biblio_mrid_to_modsbatch { warn "Creating mods batch for metarecord $mrid\n"; - my $id_hash = biblio_mrid_to_record_ids( undef, undef, $mrid ); + my $meth = "open-ils.search.biblio.metarecord_to_records"; + if( $self->api_name =~ /staff/ ) { $meth .= ".staff";} + $meth = $self->method_lookup($meth); + + my ($id_hash) = $meth->run($mrid); + my @ids = @{$id_hash->{ids}}; if(@ids < 1) { return undef; } @@ -783,6 +792,8 @@ sub biblio_mrid_to_modsbatch { warn "Master ID is $master_id\n"; # grab the master record to start the mods batch + $meth = "open-ils.storage.direct.biblio.record_entry.retrieve"; + my $record = OpenILS::Application::AppUtils->simple_scalar_request( "open-ils.storage", "open-ils.storage.direct.biblio.record_entry.retrieve", $master_id );