From 0e3e2201cec785f6721fbab802eb1a2f70331a5f Mon Sep 17 00:00:00 2001 From: edoceo Date: Fri, 1 Feb 2013 16:22:54 -0800 Subject: [PATCH] notes via unapi --- Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm index a4af2c657f..c2c1c45dea 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm @@ -78,6 +78,7 @@ sub load_record { $ctx->{marc_xml} = $rec_data[0]->{marc_xml}; $ctx->{copies} = $copy_rec->gather(1); + $ctx->{edoceo} = "Busby is Great"; $self->timelog("past store copy retrieval call"); $ctx->{copy_limit} = $copy_limit; $ctx->{copy_offset} = $copy_offset; @@ -191,6 +192,17 @@ sub mk_copy_query { $rec_id, undef, undef, $copy_limit, $copy_offset, $self->ctx->{is_staff} ); + # Add Copy Notes? + # Some How need to Make Notes an Array of Notes + # This makes two rows for the record, when there are two copy notes + $query->{select}->{acpn} = [ + {column => 'title', alias => 'note_title'}, + {column => 'value', alias => 'note_value'} + ]; + $query->{from}->{acp}->{acpn} = { + type => 'left' + }; + if($org != $self->ctx->{aou_tree}->()->id) { # no need to add the org join filter if we're not actually filtering $query->{from}->{acp}->{aou} = { -- 2.11.0