Koha/koha-tmpl/opac-tmpl/prog/en/modules/opac-reserve.tmpl
Ryan Higgins 761a589fc0 bug 1891 : bib-level itemtype was required in order to place a hold.
This patch removes some superfluous logic left over from early Koha
when a multi-step holds process allowed you to limit your choices to
specific biblioitems.itemtype values.  Code previously required a value
in biblioitems.itemtype in order to place hold.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-11-17 09:05:01 -06:00

238 lines
11 KiB
Cheetah

<!-- TMPL_INCLUDE NAME="doc-head-open.inc" --><!-- TMPL_VAR NAME="LibraryNameTitle" DEFAULT="Koha Online" --> Catalog &rsaquo; Reserving <!-- TMPL_VAR NAME="title" escape="html" --> for <!-- TMPL_LOOP NAME="USER_INFO" --><!-- TMPL_VAR NAME="firstname" --> <!-- TMPL_VAR NAME="surname" --><!-- /TMPL_LOOP -->
<!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
<script type="text/javascript">
// <![CDATA[
$(document).ready(function() {
$("#requestany").click(function() {
if(this.checked){
$("input[@name=checkitem]").each(function() {
$(this).attr("checked","");
});
}
});
$("input[@name=checkitem]").click(function() {
onechecked = 0;
$("input[@name=checkitem]").each(function() {
if(this.checked){
onechecked = 1;
}
});
if(onechecked == 1){
$("#requestany").attr("checked","");
} else {
$("#requestany").attr("checked","checked");
}
});
});
// ]]>
</script>
</head>
<body>
<div id="doc3" class="yui-t7">
<!--TMPL_INCLUDE NAME="masthead.inc" -->
<div id="bd">
<div id="yui-g">
<div id="holds" class="container">
<!-- TMPL_IF NAME="message" -->
<!-- TMPL_IF NAME="GNA" -->
<div class="dialog alert">
<strong>Sorry</strong>, you cannot place holds because the library doesn't have up-to-date <a href="/cgi-bin/koha/opac-userdetails.pl">contact information</a> on file.
</div>
<div class="dialog alert">Please contact your librarian, or use the <a href="/cgi-bin/koha/opac-userupdate.pl">online update form</a> to submit current information (<em>Please note:</em> there may be a delay in restoring your account if you submit online)
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="lost" -->
<div class="dialog alert">
<strong>Sorry</strong>, you cannot place holds because your library card has been marked as lost or stolen.
</div>
<div class="dialog alert">
If this is an error, please take your card to the circulation desk at your local library and the error will be corrected.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="debarred" -->
<div class="dialog alert">
<strong>Sorry</strong>, you cannot place holds because your account has been frozen.
</div>
<div class="dialog alert">Usually the reason for freezing an account is old overdues or damage fees. If <a href="/cgi-bin/koha/opac-user.pl">your account page</a> shows your account to be clear, please consult a librarian.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="too_much_oweing" -->
<div class="dialog alert">
Sorry, you cannot place holds because you owe <!-- TMPL_VAR NAME="too_much_oweing" -->.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="too_many_reserves" -->
<div class="dialog alert">Sorry, you cannot place more than <!-- TMPL_VAR NAME="too_many_reserves" --> holds.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="already_reserved" -->
<div class="dialog alert">
You already have a hold placed on this item. <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">Return to Item Detail Screen</a>
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="no_items_selected" -->
<div class="dialog alert">
You must select at least one item.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="no_branch_selected" -->
<div class="dialog alert">
You must select a library for pickup.
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="no_biblionumber" -->
<div class="dialog alert">ERROR: No biblionumber received.</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="bad_biblionumber" -->
<div class="dialog alert">ERROR: No biblio record found for biblionumber <!-- TMPL_VAR NAME="bad_biblionumber" -->.</div>
<!-- /TMPL_IF -->
</div>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="select_item_types" -->
<!-- The first time round you select which bibitems you want -->
<form action="/cgi-bin/koha/opac-reserve.pl" method="post">
<input type="hidden" name="item_types_selected" value="1" />
<input type="hidden" name="biblionumber" value="<!-- TMPL_VAR NAME="biblionumber" -->" />
<h3>Place a hold on <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->"><!-- TMPL_VAR NAME="title" escape="html" --></a><!-- TMPL_IF NAME="author" -->, by <!-- TMPL_VAR NAME="author" --><!-- /TMPL_IF --></h3>
<!-- TMPL_IF NAME="OPACItemHolds" --> <!-- TMPL_LOOP name="bibitemloop" -->
<!-- TMPL_UNLESS NAME="item-level_itypes" -->
<p><strong>Item type:</strong> <!-- TMPL_VAR NAME="description" --></p>
<!-- /TMPL_UNLESS -->
<!-- TMPL_IF NAME="publicationyear" --><p><strong>Publication year:</strong> <!-- TMPL_VAR NAME="publicationyear" --></p><!-- /TMPL_IF -->
<!-- /TMPL_IF --><!-- /TMPL_LOOP -->
<fieldset class="rows holds">
<ol>
<li><span class="label">For:</span> <!-- TMPL_LOOP NAME="USER_INFO" --><!-- TMPL_VAR NAME="firstname" --> <!-- TMPL_VAR NAME="surname" --> (<!-- TMPL_VAR NAME="cardnumber" -->)
<!-- TMPL_IF NAME="singleBranchMode" -->
<input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branchcode" -->"/>
<!-- /TMPL_IF -->
<!-- /TMPL_LOOP --></li>
<li><span class="label">Priority:</span><!-- TMPL_VAR Name="rank" DEFAULT="?" --> out of <!-- TMPL_VAR Name="reservecount" DEFAULT="?" -->
</li>
<!-- TMPL_UNLESS NAME="singleBranchMode" -->
<li><label for="branch">Pick up from:</label> <select name="branch" id="branch">
<!-- TMPL_LOOP NAME="CGIbranch" -->
<!-- TMPL_IF name="selected" -->
<option value="<!-- TMPL_VAR NAME="value" -->" selected="selected"><!-- TMPL_VAR NAME="branch" --></option>
<!-- TMPL_ELSE -->
<option value="<!-- TMPL_VAR NAME="value" -->"><!-- TMPL_VAR NAME="branch" --></option>
<!-- /TMPL_IF -->
<!-- /TMPL_LOOP -->
</select>
</li>
<!-- /TMPL_UNLESS -->
<!-- TMPL_IF NAME="forloan" -->
<!-- TMPL_IF NAME="OPACItemHolds" --><li> <label for="requestany">Place a hold on the next available copy </label>
<input type="checkbox" id="requestany" name="request" checked="checked" value="Any" />
</li><!-- TMPL_ELSE --><input type="hidden" name="request" value="Any" /><!-- /TMPL_IF -->
</ol>
</fieldset>
<fieldset class="action"> <input type="hidden" name="biblioitem" value="<!-- TMPL_VAR NAME="biblioitemnumber" -->" />
<input type="submit" value="Place Hold" />
<input type="hidden" name="all" value="1" />
<input type="hidden" name="place_reserve" value="1" /></fieldset>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="OPACItemHolds" --> <!-- TMPL_LOOP name="bibitemloop" -->
<table id="requestspecific">
<caption>Place a hold on a specific copy</caption>
<tr>
<th>Hold</th>
<!-- TMPL_IF NAME="item-level_itypes" -->
<th>Item Type</th>
<!-- /TMPL_IF -->
<th>Barcode</th>
<!-- TMPL_UNLESS NAME="singleBranchMode" -->
<th>Home Library</th>
<th>Last Location</th>
<!-- /TMPL_UNLESS -->
<th>Call Number</th>
<th>Information</th>
</tr>
<!-- TMPL_LOOP Name="itemloop" -->
<tr class="<!-- TMPL_VAR NAME="backgroundcolor" -->">
<td>
<!-- TMPL_IF NAME="available" -->
<input type="radio" name="checkitem" value="<!-- TMPL_VAR NAME="itemnumber" -->" />
<!-- TMPL_ELSE -->
<input disabled="disabled" type="radio" name="checkitem" value="<!-- TMPL_VAR NAME="itemnumber" -->" />
<!-- /TMPL_IF -->
</td>
<!-- TMPL_IF NAME="item-level_itypes" -->
<td>
<img src="<!-- TMPL_VAR NAME="imageurl" -->" alt="<!-- TMPL_VAR NAME="description" -->" title="<!-- TMPL_VAR NAME="description" -->" />
</td>
<!-- /TMPL_IF -->
<td><!-- TMPL_VAR NAME="barcode" --></td>
<!-- TMPL_UNLESS NAME="singleBranchMode" -->
<td><!-- TMPL_VAR NAME="homebranchname" --></td>
<td><!-- TMPL_VAR NAME="holdingbranchname" --></td>
<!-- /TMPL_UNLESS -->
<td><!-- TMPL_VAR NAME="itemcallnumber" --></td>
<td>
<!-- TMPL_IF Name="date_due" -->
<span class="checkedout">Due <!-- TMPL_VAR NAME="date_due" --></span>
<!-- TMPL_ELSIF Name="transfertwhen" -->
<span class="intransit">In transit from <!-- TMPL_VAR NAME="transfertfrom" -->,
to <!-- TMPL_VAR NAME="transfertto" -->, since <!-- TMPL_VAR NAME="transfertwhen" --></span>
<!-- /TMPL_IF -->
<!-- TMPL_IF Name="message" -->
<span class="lost">Unavailable (lost or missing)</span>
<!-- /TMPL_IF -->
<!-- TMPL_IF Name="notforloan" -->
<span class="notforloan">Not for loan (<!-- TMPL_VAR NAME="notforloanvalue" -->)</span>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="reservedate"-->
<span class="waiting"><!-- TMPL_IF NAME="waitingdate" -->Waiting<!-- TMPL_ELSE -->On hold<!-- /TMPL_IF --> for patron
<!-- TMPL_IF NAME="waitingdate" -->at<!-- TMPL_ELSE -->expected at<!-- /TMPL_IF --> <!-- TMPL_VAR NAME="ExpectedAtLibrary" -->
since
<!-- TMPL_IF NAME="waitingdate" --><!-- TMPL_VAR NAME="waitingdate" --><!-- TMPL_ELSE --><!-- TMPL_IF name="reservedate" --><!-- TMPL_VAR NAME="reservedate" --><!-- /TMPL_IF --><!-- /TMPL_IF -->.</span>
<!-- TMPL_ELSE -->
<span class="notonhold">Not on hold</span>
<!-- /TMPL_IF -->&nbsp;
</td>
</tr>
<!-- /TMPL_LOOP --> <!-- itemloop -->
</table>
<!-- /TMPL_LOOP --> <!-- bibitemloop -->
<input type="submit" value="Place Hold" />
</form><!-- /TMPL_IF -->
<!-- end of the first form -->
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="item_types_selected" -->
<!-- if the bibitems have already been selected -->
<form action="/cgi-bin/koha/opac-reserve.pl" method="post">
<input type="hidden" name="place_reserve" value="1" />
<input type="hidden" name="biblionumber" value="<!-- TMPL_VAR NAME="biblionumber" -->" /><h3>Confirm Reservation</h3>
<div class="details">
<table>
<tr><th>Title: </th><td><span class="title"><!-- TMPL_VAR NAME="title" escape="html" --></span></td></tr>
<!-- /TMPL_IF -->
<!-- TMPL_IF NAME="singleBranchMode" -->
<input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->" />
<!-- TMPL_ELSE -->
<tr><th>Pick up From: </th><td><!-- TMPL_VAR NAME="branchname" --><input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->" /></td></tr>
<!-- /TMPL_IF -->
</table>
</div>
<p><input type="submit" value="Finish and Place Reservation" class="submit" onclick="this.value='Please wait...'; this.disabled=true; this.form.submit();" /></p>
</form>
<!-- /TMPL_IF -->
</div></div>
</div>
<!-- TMPL_INCLUDE NAME="opac-bottom.inc"-->