From 306bc92ca6a5467496080ec5f0966ec58d06dae1 Mon Sep 17 00:00:00 2001 From: Terran McCanna Date: Mon, 21 Jun 2021 12:11:48 -0400 Subject: [PATCH] LP1933125 Bootstrap OPAC Hold Count Alignment This groups and styles the hold count with the available copy count. Signed-off-by: Terran McCanna Signed-off-by: Ruth Frasur Signed-off-by: Galen Charlton --- .../opac/parts/record/copy_counts.tt2 | 18 ++++++++++++++++++ .../opac/parts/record/summary.tt2 | 22 ---------------------- 2 files changed, 18 insertions(+), 22 deletions(-) diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/record/copy_counts.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/record/copy_counts.tt2 index ab2aa74df6..407662d50b 100755 --- a/Open-ILS/src/templates-bootstrap/opac/parts/record/copy_counts.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/parts/record/copy_counts.tt2 @@ -50,4 +50,22 @@ [%- END %] [%- END %] + +

[% l('Holds') %]

+
  • + [% + # If org hiding is enabled/relevant, only show + # counts for copies within the hiding scope. + count_entry = 0; + FOR count_chunk IN ctx.copy_summary; + IF ctx.org_within_hiding_scope(count_chunk.org_unit); + # always true when hiding is disabled + LAST; + END; + count_entry = count_entry + 1; + END; + l("[quant,_1,current hold,current holds] with [quant,_2,total copy,total copies].", + ctx.record_hold_count, ctx.copy_summary.$count_entry.count) + %] +
diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/record/summary.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/record/summary.tt2 index 23f521d313..a0007ed16f 100755 --- a/Open-ILS/src/templates-bootstrap/opac/parts/record/summary.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/parts/record/summary.tt2 @@ -469,28 +469,6 @@ ctx.metalinks.push('
-
- -

[% l('Holds') %]

-

- [% - # If org hiding is enabled/relevant, only show - # counts for copies within the hiding scope. - count_entry = 0; - FOR count_chunk IN ctx.copy_summary; - IF ctx.org_within_hiding_scope(count_chunk.org_unit); - # always true when hiding is disabled - LAST; - END; - count_entry = count_entry + 1; - END; - l("[quant,_1,current hold,current holds] with [quant,_2,total copy,total copies].", - ctx.record_hold_count, ctx.copy_summary.$count_entry.count) - %] -

- -
- [%- IF ctx.copy_summary.0.count; INCLUDE "opac/parts/record/copy_table.tt2" copies=ctx.copies; -- 2.11.0