[% PROCESS "opac/parts/misc_util.tt2";
PROCESS "opac/ebook_api/rbdigital/parts/file_formats.tt2";
USE ResolverResolver;
-
+
ctx.result_start = 1 + ctx.page_size * page;
ctx.result_stop = ctx.page_size * (page + 1);
IF ctx.result_stop > ctx.hit_count; ctx.result_stop = ctx.hit_count; END;
ctx.results_count_header;
%]
-
[% IF ctx.bookbag %]
<div id="result-bookbag-heading">
<div class="result-bookbag-name">[% ctx.bookbag.name | html %]</div>
</div>
<div class="result_table_utils_cont">
<div class="result_table_utils">
- [% IF ebook_item.isAvailable == 1; %]
+ [% IF (ctx.checkouts.$ebook_isbn != "") %]
<div id="[%- rec.item.isbn -%]_ebook_checkout" class="results_aux_utils result_util ebook_action">
- [% IF ctx.checkouts.$ebook_isbn != ""; %]
- <a id="[% ebook_item.isbn %]_ebook_checkout_download_link"
- href="#"
- data-downloadurl="[% ctx.checkouts.$ebook_isbn; %]"
- class="no-dec ebook_checkout_download_link"
- rel="nofollow" vocab=""
- data-isbn="[% ebook_item.isbn %]">
- <img src="[% ctx.media_prefix %]/images/minus_sign.png[% ctx.cache_key %]" alt="" /> [% l("Download") %]</a>
- <a data-isbn="[% ebook_item.isbn %]" class="lnk_ebook_checkin" href="#" ><span class="glyphicon glyphicon-circle-arrow-up"></span> [% l("Return") %]</a>
- [% ELSE; %]
+ <a id="[% ebook_item.isbn %]_ebook_checkout_download_link"
+ href="#"
+ data-downloadurl="[% ctx.checkouts.$ebook_isbn; %]"
+ class="no-dec ebook_checkout_download_link"
+ rel="nofollow" vocab=""
+ data-isbn="[% ebook_item.isbn %]">
+ <img src="[% ctx.media_prefix %]/images/minus_sign.png[% ctx.cache_key %]" alt="" /> [% l("Download") %]</a>
+ <a data-isbn="[% ebook_item.isbn %]" class="lnk_ebook_checkin" href="#" ><span class="glyphicon glyphicon-circle-arrow-up"></span> [% l("Return") %]</a>
+ </div>
+ [% ELSE; %]
+ [% IF ebook_item.isAvailable == 1; %]
+ <div id="[%- rec.item.isbn -%]_ebook_checkout" class="results_aux_utils result_util ebook_action">
<a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_checkout',
{title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'checkout'},
['query','tag','subfield','term','_special','sort','page']) %]"
data-isbn="[% ebook_item.isbn %]"
class="no-dec ebook_checkout_link" rel="nofollow" vocab="">
<img src="[% ctx.media_prefix %]/images/green_check.png[% ctx.cache_key %]"
- alt=""/><span class="result_place_hold">[% l('Check Out E-Item') %]</span></a>
- [% END; %]
- </div>
- [% ELSE; %]
- <div id="[% ebook_item.isbn %]_ebook_hold" class="rdetail_aux_utils result_util ebook_action">
- <a id="[% ebook_item.isbn %]_ebook_place_hold"
- href="#" data-isbn="[% ebook_item.isbn %]"
- class="no-dec ebook_place_hold [% IF ctx.holds.$ebook_isbn == "1"; %] hidden [% END; %]" rel="nofollow" vocab="">
- <img src="[% ctx.media_prefix %]/images/green_check.png[% ctx.cache_key %]"
- [% img_alt(l('Place Hold on [_1]', ebook_item.title)) %]/>
- <span class="result_place_hold">[% l('Place Hold on E-Item') %]</span></a>
+ alt=""/><span class="result_place_hold">[% l('Check Out E-Item') %]</span></a>
+ </div>
+
+ [% ELSE; %]
+ <div id="[% ebook_item.isbn %]_ebook_hold" class="rdetail_aux_utils result_util ebook_action">
+ <a id="[% ebook_item.isbn %]_ebook_place_hold"
+ href="#" data-isbn="[% ebook_item.isbn %]"
+ class="no-dec ebook_place_hold [% IF ctx.holds.$ebook_isbn == "1"; %] hidden [% END; %]" rel="nofollow" vocab="">
+ <img src="[% ctx.media_prefix %]/images/green_check.png[% ctx.cache_key %]"
+ [% img_alt(l('Place Hold on [_1]', ebook_item.title)) %]/>
+ <span class="result_place_hold">[% l('Place Hold on E-Item') %]</span></a>
- <a id="[% ebook_item.isbn %]_ebook_cancel_hold"
- href="#" data-isbn="[% ebook_item.isbn %]"
- class="no-dec ebook_cancel_hold [% IF ctx.holds.$ebook_isbn != "1"; %] hidden [% END; %]" rel="nofollow" vocab="">
- <img src="[% ctx.media_prefix %]/images/minus_sign.png[% ctx.cache_key %]"
- [% img_alt(l('Cancel Hold on [_1]', ebook_item.title)) %]/>
- <span class="result_place_hold">[% l('Cancel Hold on E-Item') %]</span></a>
- </div>
+ <a id="[% ebook_item.isbn %]_ebook_cancel_hold"
+ href="#" data-isbn="[% ebook_item.isbn %]"
+ class="no-dec ebook_cancel_hold [% IF ctx.holds.$ebook_isbn != "1"; %] hidden [% END; %]" rel="nofollow" vocab="">
+ <img src="[% ctx.media_prefix %]/images/minus_sign.png[% ctx.cache_key %]"
+ [% img_alt(l('Cancel Hold on [_1]', ebook_item.title)) %]/>
+ <span class="result_place_hold">[% l('Cancel Hold on E-Item') %]</span></a>
+ </div>
+ [% END; %]
[% END; %]
[% IF !ctx.is_meta %]
<div class="results_aux_utils result_util ebook_action">