From 7a83889b103b989b3633d57e61069b764509747f Mon Sep 17 00:00:00 2001 From: edoceo Date: Wed, 20 Feb 2013 18:21:29 -0800 Subject: [PATCH] Pulls the Copy Notes for the records, shows in the table, introduces a new style Signed-off-by: edoceo Signed-off-by: Mike Rylander --- .../src/perlmods/lib/OpenILS/WWW/EGCatLoader/Record.pm | 10 ++++++++++ Open-ILS/src/templates/opac/css/style.css.tt2 | 6 ++++++ .../src/templates/opac/parts/record/copy_table.tt2 | 9 ++++++++- 3 files changed, 24 insertions(+), 1 deletion(-) 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 026d7925a6..beffcbf880 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,16 @@ sub load_record { $ctx->{marc_xml} = $rec_data[0]->{marc_xml}; $ctx->{copies} = $copy_rec->gather(1); + + # Add public copy notes to each copy + foreach my $copy (@{$ctx->{copies}}) { + $copy->{notes} = $U->simplereq( + 'open-ils.circ', + 'open-ils.circ.copy_note.retrieve.all', + {itemid => $copy->{id}, pub => 1 } + ); + } + $self->timelog("past store copy retrieval call"); $ctx->{copy_limit} = $copy_limit; $ctx->{copy_offset} = $copy_offset; diff --git a/Open-ILS/src/templates/opac/css/style.css.tt2 b/Open-ILS/src/templates/opac/css/style.css.tt2 index acda930f67..fb39da263f 100644 --- a/Open-ILS/src/templates/opac/css/style.css.tt2 +++ b/Open-ILS/src/templates/opac/css/style.css.tt2 @@ -465,6 +465,12 @@ div.format_icon { padding-left: 13px; text-align: left; } +#rdetails_status tbody td.copy_note { + color: [% css_colors.primary %]; + text-wrap:normal; + white-space:pre-wrap !important; + word-wrap:normal; +} .rdetail_extras { height: 29px; diff --git a/Open-ILS/src/templates/opac/parts/record/copy_table.tt2 b/Open-ILS/src/templates/opac/parts/record/copy_table.tt2 index d75cb20325..e82ba2b6a5 100644 --- a/Open-ILS/src/templates/opac/parts/record/copy_table.tt2 +++ b/Open-ILS/src/templates/opac/parts/record/copy_table.tt2 @@ -34,7 +34,7 @@ END; [%- ELSE -%] [% l("Location") %] [%- END %] - [% l("Call Number") %] + [% l("Call Number / Copy Notes") %] [%- IF has_parts == 'true' %] [% l("Part") %] [%- END %] @@ -157,6 +157,13 @@ END; '-'; END %] + + [% IF copy_info.notes; %] + [% FOREACH note IN copy_info.notes; %] +  [% note.title | html %]: [% note.value | html %] + [% END %] + [% END %] + [%- END %] [%- IF ctx.copy_offset > 0 AND NOT serial_holdings; -- 2.43.2