From 7f2f589f82cce061f18fa1c3c0300eac2eff0a72 Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Fri, 26 Oct 2012 00:52:11 -0400 Subject: [PATCH] TPAC: don't repeat subfields in record content notes Given a MARC field like "500 $a 1 $b 2 $c 3", the content note would display as "1 1 2 1 2 3" as each subfield was appended to the total set of notes. Signed-off-by: Dan Scott Conflicts: Open-ILS/src/templates/opac/parts/record/contents.tt2 --- Open-ILS/src/templates/opac/parts/record/contents.tt2 | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Open-ILS/src/templates/opac/parts/record/contents.tt2 b/Open-ILS/src/templates/opac/parts/record/contents.tt2 index 5f460fd4df..1fb0eb5833 100644 --- a/Open-ILS/src/templates/opac/parts/record/contents.tt2 +++ b/Open-ILS/src/templates/opac/parts/record/contents.tt2 @@ -162,9 +162,10 @@ BLOCK render_contents; code = subfield.getAttribute('code'); NEXT UNLESS code.match('[a-z]'); all_content.push(subfield.textContent); - total_contents = all_content.join(" ").replace('\s+$', ''); - %][% total_contents %][%- END; - IF all_terms.size; "
"; END; + END; + total_contents = all_content.join(" ").replace('\s+$', ''); + %] [% total_contents; + IF total_contents.size; "
"; END; END; END %] -- 2.11.0