Bug 3173 Place Hold link visible in OPAC even if syspref turned off
If the syspref RequestOnOpac is turned off, the link to place a hold does not show in the detail page. However, the link is still present in the results list as well as in the basket and in lists. Modified templates to check for the syspref and to obey it. NOTE: This does not turn off the display of the Holds tab in the OPAC user account. I think there are situations where library staff may be allowed to place holds but users are not allowed to do so through the OPAC. Leaving the Holds tab visible shows users what they have on hold, but does not allow them to place holds. It does allow users to cancel holds. If there is a need to hide this tab, that would probably be best accomplished by a separate syspref. Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This commit is contained in:
parent
348d471fe0
commit
3fa269da6c
4 changed files with 15 additions and 4 deletions
|
@ -76,8 +76,10 @@ function tagAdded() {
|
|||
);
|
||||
return false;
|
||||
});
|
||||
<!-- TMPL_IF NAME="RequestOnOpac" -->
|
||||
$(".holdsep").text("| ");
|
||||
$(".hold").text("Place Hold");
|
||||
<!-- /TMPL_IF -->
|
||||
|
||||
<!-- TMPL_IF NAME="TagsEnabled" -->
|
||||
<!-- TMPL_IF NAME="TagsInputOnList" -->
|
||||
|
@ -350,4 +352,4 @@ function tagAdded() {
|
|||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
|
@ -44,7 +44,10 @@
|
|||
<!-- TMPL_IF name="pages" -->. <!-- TMPL_VAR name="pages" ESCAPE="html" --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="notes" -->, <!-- TMPL_VAR name="notes" ESCAPE="html" --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="size" --> <!-- TMPL_VAR name="size" ESCAPE="html" -->. <!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="isbn" --> <!-- TMPL_VAR name="isbn" ESCAPE="html" --><!-- /TMPL_IF --> </p><p><a href="<!-- TMPL_VAR NAME="OPACBaseURL" -->/cgi-bin/koha/opac-reserve.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">Place Hold on <i><!-- TMPL_VAR NAME="title_nospan" --></i></a></p>
|
||||
<!-- TMPL_IF name="isbn" --> <!-- TMPL_VAR name="isbn" ESCAPE="html" --><!-- /TMPL_IF --> </p><p>
|
||||
<!-- TMPL_IF NAME="RequestOnOpac" -->
|
||||
<a href="<!-- TMPL_VAR NAME="OPACBaseURL" -->/cgi-bin/koha/opac-reserve.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">Place Hold on <i><!-- TMPL_VAR NAME="title_nospan" --></i></a></p>
|
||||
<!-- /TMPL_IF -->
|
||||
]]></description>
|
||||
<guid><!-- TMPL_VAR NAME="OPACBaseURL" -->/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" --></guid>
|
||||
</item>
|
||||
|
|
|
@ -134,11 +134,13 @@ $(document).ready(function(){
|
|||
$("#bookbag_form").unCheckCheckboxes();
|
||||
return false;
|
||||
});
|
||||
<!-- TMPL_IF NAME="RequestOnOpac" -->
|
||||
$("#placehold").html("<input class=\"submit\" type=\"submit\" value=\"Place Hold\"/>");
|
||||
$("#placehold").find("input:submit").click(function(){
|
||||
holdMultiple();
|
||||
return false;
|
||||
});
|
||||
<!-- /TMPL_IF -->
|
||||
$("#holdDetails").hide();
|
||||
|
||||
<!-- TMPL_IF NAME="TagsEnabled" -->
|
||||
|
@ -414,7 +416,8 @@ $(document).ready(function(){
|
|||
<!-- TMPL_IF Name="searchhighlightblob" --><span class="results_summary"><span class="label">Match:</span> <!-- TMPL_VAR NAME="searchhighlightblob" --></span><!-- /TMPL_IF -->
|
||||
|
||||
<span class="results_summary actions"><span class="label">Actions:</span>
|
||||
<!-- TMPL_IF name="RequestOnOpac" --><!-- TMPL_UNLESS NAME="norequests" --><!-- TMPL_IF NAME="opacuserlogin" --><a class="hold" href="/cgi-bin/koha/opac-reserve.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">Place Hold</a><!-- add back when available 0 holds in queue--> <!-- /TMPL_IF --><!-- /TMPL_UNLESS --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="RequestOnOpac" --><!-- TMPL_UNLESS NAME="norequests" --><!-- TMPL_IF NAME="opacuserlogin" --><a class="hold" href="/cgi-bin/koha/opac-reserve.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">Place Hold</a><!-- add back when available 0 holds in queue--> <!-- /TMPL_IF --><!-- /TMPL_UNLESS --><!-- /TMPL_IF -->
|
||||
|
||||
|
||||
<!-- TMPL_IF NAME="opacuserlogin" --><!-- TMPL_IF NAME="loggedinusername" --><!-- TMPL_IF NAME="virtualshelves" --><a class="addtolist" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->'); return false;">Save to Lists</a>
|
||||
<!-- /TMPL_IF --><!-- /TMPL_IF --><!-- /TMPL_IF -->
|
||||
|
|
|
@ -96,8 +96,9 @@ $(function() {
|
|||
});
|
||||
|
||||
$(document).ready(function(){
|
||||
<!-- TMPL_IF NAME="RequestOnOpac" -->
|
||||
$(".hold").html("Place Hold");
|
||||
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF NAME="TagsEnabled" -->
|
||||
$("#tagsel_tag").text("Tag");
|
||||
$("#tagsel_button").click(function(){
|
||||
|
@ -177,7 +178,9 @@ $(document).ready(function(){
|
|||
<input type="submit" class="deleteshelf" value="Delete List" onclick="return confirmDelete(_('Are you sure you want to remove this List?'));"/>
|
||||
</form>
|
||||
<a href="#" class="send tag_hides" onclick="open(CGIBIN+'opac-sendshelf.pl?shelfid=<!-- TMPL_VAR NAME="shelfnumber" -->','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100')">Send List</a>
|
||||
<!-- TMPL_IF NAME="RequestOnOpac" -->
|
||||
<a href="#" class="hold tag_hides" onclick="holdSelections();return false;"></a>
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- /div -->
|
||||
<a id="tagsel_tag" href="#" onclick="tagSelected(); return false;"></a>
|
||||
<span id="tagsel_form" style="display:none">
|
||||
|
|
Loading…
Reference in a new issue