TPAC - Allow looking at non-available copies user/tsbere/tpac_record_copy_counts
authorThomas Berezansky <tsbere@mvlc.org>
Wed, 12 Sep 2012 20:56:45 +0000 (16:56 -0400)
committerThomas Berezansky <tsbere@mvlc.org>
Wed, 12 Sep 2012 20:56:45 +0000 (16:56 -0400)
There are lots of reasons, on the staff side or otherwise, to want to see
copies at a given depth that are not available. So draw it even if there
are no available copies, so long as there are copies.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Open-ILS/src/templates/opac/parts/record/copy_counts.tt2

index 288c31b..fc38192 100644 (file)
     %]
     <li>
     [%- this_depth = ctx.get_aou(ou_id).ou_type.depth;
-        IF ou_avail > 0 && this_depth != ctx.copy_depth %]
+        IF ou_count > 0 && this_depth != ctx.copy_depth %]
     <a href="[% mkurl('', {copy_depth => this_depth}, ['copy_offset']); %]"
        title="[% l('Show copies at [_1]', ou_name); %]">
     [%- END; %]
     [% l('[_1] of [quant,_2,copy,copies] at [_3].', ou_avail, ou_count, ou_name) | html %]
-    [%- IF ou_avail > 0 && this_depth != ctx.copy_depth -%]
+    [%- IF ou_count > 0 && this_depth != ctx.copy_depth -%]
        </a>
     [%- END; %]
     </li>