Lines 35-40
function verify_images() {
Link Here
|
35 |
} |
35 |
} |
36 |
}); |
36 |
}); |
37 |
} |
37 |
} |
|
|
38 |
|
39 |
[% IF StaffDetailItemSelection %] |
40 |
function selectAllItems(div) { |
41 |
$("input[name='itemnumber'][type='checkbox']", div).attr('checked', 'checked'); |
42 |
} |
43 |
|
44 |
function deselectAllItems(div) { |
45 |
$("input[name='itemnumber'][type='checkbox']", div).removeAttr('checked'); |
46 |
} |
47 |
|
48 |
function itemSelectionExecuteAction(div) { |
49 |
var itemnumbers = new Array(); |
50 |
$("input[name='itemnumber'][type='checkbox']:checked", div).each(function() { |
51 |
itemnumbers.push($(this).val()); |
52 |
}); |
53 |
if (itemnumbers.length > 0) { |
54 |
var action = $('select[name="itemselection_action"]', div).val(); |
55 |
var del = (action == 'delete') ? 1 : 0; |
56 |
var url = '/cgi-bin/koha/tools/batchMod.pl?op=show'; |
57 |
if (action == 'delete') { |
58 |
url += '&del=1'; |
59 |
} |
60 |
url += '&itemnumber=' + itemnumbers.join('&itemnumber='); |
61 |
url += '&src=' + '[% "/cgi-bin/koha/catalogue/detail.pl?biblionumber=$biblionumber" |uri %]'; |
62 |
new_window = $("input[name='new_window']", div).attr('checked'); |
63 |
if (new_window) { |
64 |
window.open(url); |
65 |
} else { |
66 |
window.location.href = url; |
67 |
} |
68 |
} else { |
69 |
alert(_("Please select at least one item.")); |
70 |
} |
71 |
} |
72 |
[% END %] |
73 |
|
38 |
$(document).ready(function() { |
74 |
$(document).ready(function() { |
39 |
$('#bibliodetails').tabs(); |
75 |
$('#bibliodetails').tabs(); |
40 |
$('#search-form').focus(); |
76 |
$('#search-form').focus(); |
Lines 266-273
function verify_images() {
Link Here
|
266 |
<div id="holdings"> |
302 |
<div id="holdings"> |
267 |
[% IF ( count ) %] |
303 |
[% IF ( count ) %] |
268 |
[% IF ( showncount ) %] |
304 |
[% IF ( showncount ) %] |
|
|
305 |
[% IF (StaffDetailItemSelection) %] |
306 |
<a href="#" onclick="selectAllItems($(this).parent()); return false;">Select all</a> | |
307 |
<a href="#" onclick="deselectAllItems($(this).parent()); return false;">Deselect all</a> | |
308 |
<form onsubmit="itemSelectionExecuteAction($(this).parent()); return false;"> |
309 |
<label>Action:</label> |
310 |
<select name="itemselection_action"> |
311 |
[% IF CAN_user_tools_items_batchdel %] |
312 |
<option value="delete">Delete selected items</option> |
313 |
[% END %] |
314 |
[% IF CAN_user_tools_items_batchmod %] |
315 |
<option value="modify">Modify selected items</option> |
316 |
[% END %] |
317 |
</select> |
318 |
<input type="submit" value="Go" /> |
319 |
<input type="checkbox" name="new_window" /> |
320 |
<label>Open in new window</label> |
321 |
</form> |
322 |
[% END %] |
269 |
<table> |
323 |
<table> |
270 |
<tr> |
324 |
<tr> |
|
|
325 |
[% IF (StaffDetailItemSelection) %]<th></th>[% END %] |
271 |
[% IF ( item_level_itypes ) %]<th>Item type</th>[% END %] |
326 |
[% IF ( item_level_itypes ) %]<th>Item type</th>[% END %] |
272 |
<th>Current location</th> |
327 |
<th>Current location</th> |
273 |
<th>Home Library</th> |
328 |
<th>Home Library</th> |
Lines 287-292
function verify_images() {
Link Here
|
287 |
</tr> |
342 |
</tr> |
288 |
[% FOREACH itemloo IN itemloop %] |
343 |
[% FOREACH itemloo IN itemloop %] |
289 |
<tr> |
344 |
<tr> |
|
|
345 |
[% IF (StaffDetailItemSelection) %] |
346 |
<td style="text-align:center;vertical-align:middle"> |
347 |
<input type="checkbox" value="[% itemloo.itemnumber %]" name="itemnumber" /> |
348 |
</td> |
349 |
[% END %] |
290 |
[% IF ( item_level_itypes ) %] |
350 |
[% IF ( item_level_itypes ) %] |
291 |
<td class="itype"> |
351 |
<td class="itype"> |
292 |
[% IF !noItemTypeImages && itemloo.imageurl %] |
352 |
[% IF !noItemTypeImages && itemloo.imageurl %] |