[open-ils-commits] [GIT] Evergreen ILS branch master updated. 19b81874ffbdf91f4acbe93f8e8f4c44f111c6a1

Evergreen Git git at git.evergreen-ils.org
Tue Nov 1 12:24:26 EDT 2011


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  19b81874ffbdf91f4acbe93f8e8f4c44f111c6a1 (commit)
      from  0c29090151e896568214eef2ed2ae69b49c16974 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 19b81874ffbdf91f4acbe93f8e8f4c44f111c6a1
Author: Bill Erickson <berick at esilibrary.com>
Date:   Tue Nov 1 11:35:41 2011 -0400

    Tpac; bookbag MARC retrieved via unapi
    
    Make sure the bookbag interface has access to metabib.record_attr's by
    retrieving and parsing the marcxml via unapi (get_records_and_facets).
    
    Signed-off-by: Bill Erickson <berick at esilibrary.com>
    Signed-off-by: Mike Rylander <mrylander at gmail.com>

diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
index fe0da83..c84bed4 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
@@ -1399,14 +1399,13 @@ sub load_myopac_bookbags {
         my $items = $U->bib_container_items_via_search($bookbag->id, $query)
             or return Apache2::Const::HTTP_INTERNAL_SERVER_ERROR;
 
-        # Maybe save a little memory by creating only one XML::LibXML::Document
-        # instance for each record, even if record is repeated across bookbags.
+        my (undef, @recs) = $self->get_records_and_facets(
+            [ map {$_->target_biblio_record_entry->id} @$items ],
+            undef, 
+            {flesh => '{mra}'}
+        );
 
-        foreach my $rec (map { $_->target_biblio_record_entry } @$items) {
-            next if $ctx->{bookbags_marc_xml}{$rec->id};
-            $ctx->{bookbags_marc_xml}{$rec->id} =
-                (new XML::LibXML)->parse_string($rec->marc);
-        }
+        $ctx->{bookbags_marc_xml}{$_->{id}} = $_->{marc_xml} for @recs;
 
         $bookbag->items($items);
     }

-----------------------------------------------------------------------

Summary of changes:
 .../lib/OpenILS/WWW/EGCatLoader/Account.pm         |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list