|
Lines 42-47
function verify_images() {
Link Here
|
| 42 |
[% IF ( AmazonEnabled ) %]$(window).load(function() { |
42 |
[% IF ( AmazonEnabled ) %]$(window).load(function() { |
| 43 |
verify_images(); |
43 |
verify_images(); |
| 44 |
});[% END %] |
44 |
});[% END %] |
|
|
45 |
|
| 46 |
|
| 47 |
//AJAX call to send a recall notice to the user who currently has the item. |
| 48 |
function recall_item(itemnumber) { |
| 49 |
var button = $("#recall_"+itemnumber); |
| 50 |
|
| 51 |
if(!confirm(_('A request for the immediate return of the item will be sent to the user who currently has it in its possession.\n\nAre you sure you want to send a recall notice?'))) { |
| 52 |
return; |
| 53 |
} |
| 54 |
|
| 55 |
//Disable the button to prevent spamming |
| 56 |
button.attr("disabled",true); |
| 57 |
|
| 58 |
$.ajax({ |
| 59 |
url: '/cgi-bin/koha/circ/send_recall_notice.pl', |
| 60 |
type: 'POST', |
| 61 |
dataType: 'text', |
| 62 |
data: {itemnumber: itemnumber}, |
| 63 |
success: function(msg){ |
| 64 |
if(msg == "SUCCESS") { |
| 65 |
button.attr("value",_("Recall sent")); |
| 66 |
} |
| 67 |
else if(msg == "UNAUTHORIZED") { |
| 68 |
alert(_("Failed to send the recall notice:")+"\n"+_("You do not have the required permissions to do this action.")+" (circulate_remaining_permissions)"); |
| 69 |
button.attr("disabled",false); |
| 70 |
} |
| 71 |
else { |
| 72 |
alert(_("Failed to send the recall notice:")+"\n"+msg); |
| 73 |
button.attr("disabled",false); |
| 74 |
} |
| 75 |
}, |
| 76 |
error: function(request,status){ |
| 77 |
alert(_("Failed to send the recall notice:")+"\n"+status); |
| 78 |
button.attr("disabled",false); |
| 79 |
} |
| 80 |
}); |
| 81 |
} |
| 82 |
|
| 45 |
//]]> |
83 |
//]]> |
| 46 |
</script> |
84 |
</script> |
| 47 |
</head> |
85 |
</head> |
|
Lines 285-290
function verify_images() {
Link Here
|
| 285 |
[% IF ( SpineLabelShowPrintOnBibDetails ) %]<th>Spine label</th>[% END %] |
323 |
[% IF ( SpineLabelShowPrintOnBibDetails ) %]<th>Spine label</th>[% END %] |
| 286 |
[% IF ( hostrecords ) %]<th>Host records</th>[% END %] |
324 |
[% IF ( hostrecords ) %]<th>Host records</th>[% END %] |
| 287 |
[% IF ( analyze ) %]<th>Used in</th><th></th>[% END %] |
325 |
[% IF ( analyze ) %]<th>Used in</th><th></th>[% END %] |
|
|
326 |
[% IF ( items_checked_out ) %]<th>Recall</th>[% END %] |
| 288 |
</tr> |
327 |
</tr> |
| 289 |
[% FOREACH itemloo IN itemloop %] |
328 |
[% FOREACH itemloo IN itemloop %] |
| 290 |
<tr> |
329 |
<tr> |
|
Lines 421-426
function verify_images() {
Link Here
|
| 421 |
<td><a href="/cgi-bin/koha/cataloguing/addbiblio.pl?hostbiblionumber=[% itemloo.biblionumber %]&hostitemnumber=[% itemloo.itemnumber %]">Create analytics</a></td> |
460 |
<td><a href="/cgi-bin/koha/cataloguing/addbiblio.pl?hostbiblionumber=[% itemloo.biblionumber %]&hostitemnumber=[% itemloo.itemnumber %]">Create analytics</a></td> |
| 422 |
[% END %] |
461 |
[% END %] |
| 423 |
|
462 |
|
|
|
463 |
[% IF ( items_checked_out ) %] |
| 464 |
<td> |
| 465 |
[% IF ( itemloo.onloan ) %] |
| 466 |
<input type="button" id="recall_[% itemloo.itemnumber %]" name="recall_[% itemloo.itemnumber %]" value="Recall" onclick="recall_item([% itemloo.itemnumber %]);" /> |
| 467 |
[% END %] |
| 468 |
</td> |
| 469 |
[% END %] |
| 470 |
|
| 424 |
</tr> |
471 |
</tr> |
| 425 |
[% END %] |
472 |
[% END %] |
| 426 |
</table> |
473 |
</table> |
| 427 |
- |
|
|