--- /dev/null
+[% PROCESS "opac/parts/header.tt2";
+ PROCESS "opac/parts/misc_util.tt2";
+ PROCESS "opac/parts/myopac/column_sort_support.tt2";
+ WRAPPER "opac/parts/myopac/base.tt2";
+ myopac_page = "ebook_checkout";
+%]
+<h3 class="sr-only">[% l('Check Out E-Item') %]</h3>
+<div id='myopac_checked_div'>
+
+ <div class="header_middle">
+ <span class="float-left">[% l('Check Out E-Item') %]</span>
+ </div>
+ <div class="clear-both"></div>
+ <div id="ebook_checkout_failed" class="warning_box hidden">[% l('E-item could not be checked out.') %]</div>
+ <div id="ebook_checkout_succeeded" class="success hidden">[% l('E-item successfully checked out.') %]</div>
+ <div id='ebook_circs_main' class="hidden">
+ <table id="ebook_circs_main_table"
+ title="[% l('Check Out E-Item') %]"
+ class="table_no_border_space table_no_cell_pad item_list_padding">
+ <thead>
+ <tr>
+ <th>[% l("Title") %]</th>
+ <th>[% l("Author") %]</th>
+ <th>[% l("Due Date") %]</th>
+ <th>[% l("Actions") %]</th>
+ </tr>
+ </thead>
+ <tbody id="ebook_circs_main_table_body"></tbody>
+ </table>
+ </div>
+</div>
+[% END %]
+
PROCESS "opac/parts/myopac/column_sort_support.tt2";
WRAPPER "opac/parts/myopac/base.tt2";
myopac_page = "ebook_circs";
- IF CGI.param("action") == 'checkout';
- ebook_circs_title = l('Check Out E-Item');
- ELSE;
- ebook_circs_title = l('E-Items Currently Checked Out');
- END;
%]
<h3 class="sr-only">[% l('E-Items Currently Checked Out') %]</h3>
<div id='myopac_checked_div'>
</div>
<div class="header_middle">
- <span class="float-left">[% ebook_circs_title %]</span>
+ <span class="float-left">[% l('E-Items Currently Checked Out') %]</span>
</div>
<div class="clear-both"></div>
<div id="no_ebook_circs" class="warning_box hidden">[% l('You have no e-items checked out.') %]</div>
- <div id="ebook_checkout_failed" class="warning_box hidden">[% l('E-item could not be checked out.') %]</div>
- <div id="ebook_checkout_succeeded" class="success hidden">[% l('E-item successfully checked out.') %]</div>
<div id='ebook_circs_main' class="hidden">
<table id="ebook_circs_main_table"
- title="[% ebook_circs_title %]"
+ title="[% l('E-Items Currently Checked Out') %]"
class="table_no_border_space table_no_cell_pad item_list_padding">
<thead>
<tr>
PROCESS "opac/parts/myopac/column_sort_support.tt2";
WRAPPER "opac/parts/myopac/base.tt2";
myopac_page = "ebook_holds";
- IF CGI.param("action") == 'place_hold';
- ebook_holds_title = l('Place Hold on E-Item');
- ELSIF CGI.param("action") == 'cancel_hold';
- ebook_holds_title = l('Cancel Hold on E-Item');
- ELSE;
- ebook_holds_title = l('E-Items on Hold');
- END;
limit = (ctx.holds_limit.defined) ? ctx.holds_limit : 0;
offset = (ctx.holds_offset.defined) ? ctx.holds_offset : 0;
count = (ctx.holds_ids.size.defined) ? ctx.holds_ids.size : 0;
</div>
<div class="header_middle">
- <span class="float-left">[% ebook_holds_title %]</span>
+ <span class="float-left">[% l('E-Items on Hold') %]</span>
</div>
<div class="clear-both"></div>
<div id="no_ebook_holds" class="warning_box hidden">[% l('You have no e-item holds.') %]</div>
- <div id="ebook_place_hold_failed" class="warning_box hidden">[% l('Hold could not be placed.') %]</div>
- <div id="ebook_place_hold_succeeded" class="success hidden">[% l('E-item is now on hold.') %]</div>
<div id="ebook_cancel_hold_failed" class="warning_box hidden">[% l('Hold could not be canceled.') %]</div>
<div id="ebook_cancel_hold_succeeded" class="success hidden">[% l('Your hold has been canceled.') %]</div>
<div id='ebook_holds_main' class="hidden">
<table id="ebook_holds_main_table"
- title="[% ebook_holds_title %]"
+ title="[% l('E-Items on Hold') %]"
class="table_no_border_space table_no_cell_pad item_list_padding">
<thead>
<tr>
--- /dev/null
+[% PROCESS "opac/parts/header.tt2";
+ PROCESS "opac/parts/misc_util.tt2";
+ PROCESS "opac/parts/hold_status.tt2";
+ PROCESS "opac/parts/myopac/column_sort_support.tt2";
+ WRAPPER "opac/parts/myopac/base.tt2";
+ myopac_page = "ebook_place_hold";
+%]
+<h3 class="sr-only">[% l('Place Hold on E-Item') %]</h3>
+<div id='myopac_holds_div'>
+
+ <div class="header_middle">
+ <span class="float-left">[% l('Place Hold on E-Item') %]</span>
+ </div>
+ <div class="clear-both"></div>
+ <div id="ebook_place_hold_failed" class="warning_box hidden">[% l('Hold could not be placed.') %]</div>
+ <div id="ebook_place_hold_succeeded" class="success hidden">[% l('E-item is now on hold.') %]</div>
+ <div id='ebook_holds_main' class="hidden">
+ <table id="ebook_holds_main_table"
+ title="[% l('Place Hold on E-Item') %]"
+ class="table_no_border_space table_no_cell_pad item_list_padding">
+ <thead>
+ <tr>
+ <th>[% l("Title") %]</th>
+ <th>[% l("Author") %]</th>
+ <th>[% l("Expire Date") %]</th>
+ <th>[% l("Status") %]</th>
+ <th>[% l("Actions") %]</th>
+ </tr>
+ </thead>
+ <tbody id="ebook_holds_main_table_body"></tbody>
+ </table>
+ </div>
+</div>
+[% END %]
+
[%- IF ebook_api.enabled == 'true' && args.ebook %]
<div id="[%- ctx.bre_id -%]_ebook_checkout" class="rdetail_aux_utils ebook_action hidden">
- <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_circs',
+ <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_checkout',
{title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'checkout'}, stop_parms) %]"
class="no-dec" rel="nofollow" vocab=""><img src="[% ctx.media_prefix %]/images/green_check.png"
[% img_alt(l('Check Out [_1]', attrs.title)) %]/>
<span class="place_hold">[% l('Check Out E-Item') %]</span></a>
</div>
<div id="[%- ctx.bre_id -%]_ebook_place_hold" class="rdetail_aux_utils ebook_action hidden">
- <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_holds',
+ <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_place_hold',
{title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'place_hold'}, stop_parms) %]"
class="no-dec" rel="nofollow" vocab=""><img src="[% ctx.media_prefix %]/images/green_check.png"
[% img_alt(l('Place Hold on [_1]', attrs.title)) %]/>
[%- IF ebook_api.enabled == 'true' && args.ebook %]
<div id="[%- rec.id -%]_ebook_checkout" class="results_aux_utils result_util ebook_action hidden">
- <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_circs',
+ <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']) %]"
[% html_text_attr('title', l('Check Out [_1]', attrs.title)) %]
alt=""/><span class="result_place_hold">[% l('Check Out E-Item') %]</span></a>
</div>
<div id="[%- rec.id -%]_ebook_place_hold" class="results_aux_utils result_util ebook_action hidden">
- <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_holds',
+ <a href="[% mkurl(ctx.opac_root _ '/myopac/ebook_place_hold',
{title => args.ebook.ebook_id, vendor => args.ebook.vendor, action => 'place_hold'},
['query','tag','subfield','term','_special','sort','page']) %]"
[% html_text_attr('title', l('Place Hold on [_1]', attrs.title)) %]
updateHoldView();
if (myopac_page === 'ebook_holds_ready')
updateHoldView();
+ if (myopac_page === 'ebook_checkout')
+ getReadyForCheckout();
+ if (myopac_page === 'ebook_place_hold')
+ getReadyForHold();
}
}
}
function updateCheckoutView() {
- if (typeof ebook_action.type !== 'undefined') {
- if (ebook_action.type == 'checkout') {
- getReadyForCheckout();
- }
- } else if (xacts.checkouts.length < 1) {
+ if (xacts.checkouts.length < 1) {
dojo.removeClass('no_ebook_circs', "hidden");
} else {
dojo.forEach(xacts.checkouts, function(x) {
}
function updateHoldView() {
- // handle hold actions
- if (typeof ebook_action.type !== 'undefined') {
- getReadyForHold();
- return;
- }
-
if (myopac_page === 'ebook_holds_ready') {
// only show holds that are ready for checkout
var holds = xacts.holds_ready;