[%- # If being used in serial mode, flatten list of units so that they can be # used like one long list of copies without changing so much code below. IF serial_holdings; copies = []; FOREACH h IN serial_holdings; units = h.units.slice(0); # copy FOREACH unit IN units; unit.holding_label = h.label; END; copies = copies.merge(units); END; END; FOREACH copy_info IN copies; IF copy_info.call_number_label != '##URI##'; has_copies = 'true'; END; IF copy_info.part_label != ''; has_parts = 'true'; END; IF has_parts && has_copies; LAST; END; END; -%] [%- IF has_copies; %]
[% l("Issue Label") %] | [%- ELSE -%][% l("Location") %] | [%- END %][% l("Call Number") %] | [%- IF has_parts == 'true' %][% l("Part") %] | [%- END %][% l("Barcode") %] | [% l("Shelving Location") %] | [%- IF ctx.is_staff %][% l("Age Hold Protection") %] | [% l("Create Date") %] | [%- END %] [%- IF ctx.is_staff OR serial_holdings %][% l("Holdable?") %] | [%- END %][% l("Status") %] | [% l("Due Date") %] |
---|---|---|---|---|---|---|---|---|---|---|
[%- copy_info.holding_label | html; -%] | [%- ELSE %][%- org_name = ctx.get_aou(copy_info.circ_lib).name; org_name | html -%] | [% END %][% callnum | html %] [% IF ctx.get_org_setting(CGI.param('loc') OR ctx.aou_tree.id, 'sms.enable') == 1 %](Text)[% END %] | [%- IF has_parts == 'true' %][% copy_info.part_label | html %] | [%- END %][%- IF ctx.is_staff -%] [% copy_info.barcode | html %] [%- ELSE -%][% copy_info.barcode | html %] [%- END -%] | [% copy_info.copy_location | html %] | [%- IF ctx.is_staff %][% copy_info.age_protect ? ctx.get_crahp(copy_info.age_protect).name : l('None') | html %] | [% date.format( ctx.parse_datetime(copy_info.create_date), DATE_FORMAT ) %] | [% END # is_staff %] [% IF ctx.is_staff OR serial_holdings %][% # Show copy/volume hold links to staff (without # checking whether they have permissions to do those). overall_holdable = ( copy_info.holdable == 't' AND copy_info.location_holdable == 't' AND copy_info.status_holdable == 't'); IF overall_holdable; l("Place on"); IF ctx.is_staff; %] [% l("copy") %] [%- IF copy_info.call_number != last_cn; last_cn = copy_info.call_number; l(" / "); %] [% l("volume") %] [%- END; IF serial_holdings; l(" / "); END; END; IF serial_holdings; %] [% l("issue") %][%- END; ELSE; l("No"); END %] | [%- END %][% copy_info.copy_status | html %] | [% IF copy_info.due_date; date.format( ctx.parse_datetime(copy_info.due_date), DATE_FORMAT ); ELSE; '-'; END %] |
« [% l('Previous [_1]', ctx.copy_offset - new_offset) %] | [%- END %] [%- IF copies.size >= ctx.copy_limit AND NOT serial_holdings %][% l('Next [_1]', ctx.copy_limit) %] » | [%- END %]|||||||||
[%- more_copies_limit = 50 %] [%# TODO: config %] [%- IF ctx.copy_limit != more_copies_limit AND copies.size >= ctx.copy_limit %] [%- ELSIF ctx.copy_limit == more_copies_limit %] [%- END %] |