<title>[% l('Catalog - [_1]', ctx.page_title) %]</title>
<meta name="viewport" content="format-detection=no,initial-scale=1.0,maximum-scale=1.0,user-scalable=0,width=device-width" />
<style type='text/css'>
+ body { color: #4D4D4D; }
+ body a, a:visited { color: #4D4D4D;}
h1 { font-size: 140%; }
h2 { font-size: 110%; }
.hidden { visibility: hidden }
- .results_paginate { margin: 8px }
+ .results_paginate { margin: 8px; width: 100%; text-align: center; }
.results_paginate_summary { margin-bottom: 10px; }
- .results_paginate_links { margin-bottom: 10px; padding-bottom: 10px; border-bottom: 2px dashed #333;}
+ .results_paginate_links { margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px dashed #333;}
.results_table { width: 100%; border-collapse: collapse;}
.results_table td { padding-bottom: 10px; vertical-align: bottom}
- .results_table tr:nth-child(odd) { background: #F8F5D8; color: #4D4D4D; border-bottom:1px solid #4D4D4D;}
- .results_table a, a:visited { color: #4D4D4D;}
- .results_pictd { width:55px }
+ .results_table tr:nth-child(odd) { background: #F8F5D8; border-bottom:1px solid #4D4D4D;}
+ .results_pictd { width: 55px }
+ .pageno_link { font-size: 120%; padding: 0px 5px 0px 5px;}
</style>
</head>
- <body>
- [% content %]
- </body>
+ <body>[% content %]</body>
</html>
--- /dev/null
+[%-
+
+# 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; %]
+ [%- last_cn = 0;
+ FOR copy_info IN copies;
+ callnum = copy_info.call_number_label;
+ NEXT IF callnum == '##URI##';
+
+ callnum_prefix = copy_info.call_number_prefix_label;
+ IF callnum_prefix != "";
+ callnum = callnum_prefix _ " " _ callnum;
+ END;
+
+ callnum_suffix = copy_info.call_number_suffix_label;
+ IF callnum_suffix != "";
+ callnum = callnum _ " " _ callnum_suffix;
+ END;
+ -%]
+ <div>
+ <div>[% callnum | html %]</div>
+ <ul>
+ <li>[% l('Location: [_1]', ctx.get_aou(copy_info.circ_lib).name) | html %]</li>
+ <li>[% l('Shelf: [_1]', copy_info.copy_location) | html %]</li>
+ <li>[% l('Barcode: [_1]', copy_info.barcode) | html %]</li>
+ <li>[% l('Status: [_1]', copy_info.copy_status) | html %]</li>
+ [% IF copy_info.due_date %]
+ <li>[% l('Due Date: [_1]', date.format(ctx.parse_datetime(copy_info.due_date), DATE_FORMAT)) %]</li>
+ [% END %]
+ </ul>
+ </div>
+[% END %]
+ <div>
+ [%- IF ctx.copy_offset > 0 AND NOT serial_holdings;
+ new_offset = ctx.copy_offset - ctx.copy_limit;
+ IF new_offset < 0; new_offset = 0; END %]
+ <span>
+ <a href="[% mkurl('', {copy_offset => new_offset, copy_limit => ctx.copy_limit}) %]">« [%
+ l('Previous [_1]', ctx.copy_offset - new_offset) %]</a>
+ </span>
+ [%- END %]
+ [%- IF copies.size >= ctx.copy_limit AND NOT serial_holdings %]
+ <span>
+ <a href="[% mkurl('', {copy_offset => ctx.copy_offset + ctx.copy_limit, copy_limit => ctx.copy_limit}) %]">[%
+ l('Next [_1]', ctx.copy_limit) %] »</a>
+ </span>
+ [%- END %]
+
+[% END %]
%]
<div class='results_paginate'>
+ [% IF paginate_show_summary %]
<div class='results_paginate_summary'>
[% |l(ctx.result_start, ctx.result_stop, ctx.hit_count) %]
Results <strong>[_1]</strong> - <strong>[_2]</strong> of <strong>[_3]</strong>
[% |l(page + 1, page_count) %](page <strong>[_1]</strong> of <strong>[_2]</strong>)[% END %]
</span>
</div>
+ [% END %]
<div class='results_paginate_links'>
<span>
-
[% class = '';
href = '#';
IF page > 0;
ELSE; class = class _ 'invisible'; END;
%]
<a class='[% class %]' href='[% href %]'
- title='[% l("Previous page") %]'><span><--</span> [% l('Previous') %] </a>
+ title='[% l("Previous page") %]'><img src="[% ctx.media_prefix %]/images/left_arrow.png"/></a>
<span style='padding-left: 11px; padding-right:11px;'>
[% # show links to 4 previous pages, the current page, and 3 more pages.
WHILE (pageitr = pageitr + 1) < page_count;
IF pageitr < 0; NEXT; END;
IF pageitr == page; %]
- <span>[% pageitr + 1%]</span>
+ <span class='pageno_link'>[% pageitr + 1%]</span>
[% ELSE %]
- <a href="[% mkurl('', {page => pageitr}) %]">[% pageitr + 1%]</a>
+ <a class='pageno_link' href="[% mkurl('', {page => pageitr}) %]">[% pageitr + 1%]</a>
[% END;
added = added + 1;
IF added == 8; LAST; END;
ELSE; class = class _ ' invisible'; END;
%]
<a class='[% class %]' href='[% href %]'
- title='[% l("Next page") %]'> [% l('Next') %] <span>--></span></a>
+ title='[% l("Next page") %]'><img src="[% ctx.media_prefix %]/images/right_arrow.png"/></a>
</span>
</div>
</div>
[%- END %]
</ul>
+<hr/>
+[% l('Copies') %]
+<hr/>
+
+[%- INCLUDE "beanstalk/copy_table.tt2" copies=ctx.copies %]
[% END %]
ctx.page_title = l("Search Results: ") _ CGI.param('query') | html;
%]
-[% PROCESS results_paginate %]
+[% PROCESS results_paginate paginate_show_summary=1 %]
<table class='results_table'>
[% FOR rec IN ctx.records;
</table>
-[% PROCESS results_paginate %]
+[% PROCESS results_paginate paginate_show_summary=0 %]
[% END %]