1 [% PROCESS "opac/parts/header.tt2";
2 PROCESS "opac/parts/misc_util.tt2";
3 WRAPPER "opac/parts/myopac/base.tt2";
4 myopac_page = "circs" %]
5 <div id='myopac_checked_div'>
7 <div id="acct_checked_tabs">
8 <div class="align selected">
9 <a href="#">[% l("Current Items Checked Out") %]</a>
12 <a href="[% mkurl('circ_history') %]">[% l("Check Out History") %]</a>
16 <div class="header_middle">
17 <span class="float-left">[% l('Current Items Checked Out') %]</span>
19 <div class="clear-both"></div>
20 [% IF ctx.circs.size < 1 %]
21 <div class="warning_box">[% l('You have no items checked out.') %]</div>
23 [% IF ctx.success_renewals %]
24 <div class="renew-summary">
25 [% l("Successfully renewed [_1] item(s)", ctx.success_renewals) %]
28 [% IF ctx.failed_renewals %]
29 <div class="renew-summary alert">
30 [% l("Failed to renew [_1] item(s)", ctx.failed_renewals) %]
33 <div id='checked_main'>
34 <form method="post" id="circ-form"
35 onsubmit="return confirm('[% l("Are you sure you wish to renew the selected item(s)?") %]');">
38 <select name="action" title="[% l('Select Action') %]">
39 <option value="renew">[% l('Renew Selected Titles') %]</option>
42 <span style="padding-left:9px;">
46 class="opac-button" />
48 <span style="padding-left:5px;">
50 alt="[% l('Renewing Help') %]"
51 title="[% l('Actions for checked out items') %]"
52 src="[% ctx.media_prefix %]/images/question-mark.png" /></a>
56 <table id="acct_checked_main_header"
57 title="[% l('Items Checked Out') %]"
58 class="table_no_border_space table_no_cell_pad item_list_padding">
61 <th class="checkbox_column">
62 <input type="checkbox" id="check_all_checked"
63 title="[% l('Select All Items') %]"
64 onclick="var inputs=document.getElementsByTagName('input'); for (i = 0; i < inputs.length; i++) { if (inputs[i].name == 'circ' && !inputs[i].disabled) inputs[i].checked = this.checked;}"
67 <th>[% l('Title / Author') %]</th>
68 <th>[% l('Renewals Left') %]</th>
69 <th>[% l('Due Date') %]</th>
70 <th>[% l('Barcode') %]</th>
71 <th>[% l('Call number') %]</th>
75 [% FOR circ IN ctx.circs;
76 attrs = {marc_xml => circ.marc_xml};
77 PROCESS get_marc_attrs args=attrs; %]
79 <td class="checkbox_column" valign="top">
80 <input type="checkbox" name="circ"
81 title="[% l('Item Selected') %]"
82 [% IF circ.circ.renewal_remaining < 1 %] disabled="disabled" [% END %]
83 value="[% circ.circ.id %]" />
86 [% IF circ.circ.target_copy.call_number.id == -1 %]
87 [% circ.circ.target_copy.dummy_title | html %]
88 [% ELSIF attrs.title %]
89 <a href="[% mkurl(ctx.opac_root _ '/record/' _
90 circ.circ.target_copy.call_number.record.id) %]"
91 name="[% l('Catalog record') %]">[% attrs.title | html %]</a>
93 [% IF circ.circ.target_copy.call_number.id == -1 %] /
94 [% circ.circ.target_copy.dummy_author | html %]
95 [% ELSIF attrs.author %] /
96 <a href="[% mkurl(ctx.opac_root _ '/results',
97 {qtype => 'author', query => attrs.author.replace('[,\.:;]', '')}
98 ) %]">[% attrs.author | html %]</a>
102 [% circ.circ.renewal_remaining %]
105 due_date = ctx.parse_datetime(circ.circ.due_date);
106 due_class = (date.now > date.format(due_date, '%s')) ? 'error' : '';
108 <td name="due_date" class='[% due_class %]'>
109 [% date.format(due_date, DATE_FORMAT) %]
112 [% circ.circ.target_copy.barcode | html %]
114 <td name="call_number">
115 [% circ.circ.target_copy.call_number.label | html %]
118 [% IF circ.renewal_response AND
119 circ.renewal_response.textcode != 'SUCCESS' %]
121 <td colspan="6">[%# XXX colspan="0" does not work in IE %]
122 <span class="failure-text" title="[% circ.renewal_response.textcode | html %] / [% circ.renewal_response.payload.fail_part | html %]">
123 [% (circ.renewal_response.desc || circ.renewal_response.payload.fail_part || circ.renewal_response.textcode) | html %]