View | Details | Raw Unified | Return to bug 9757
Collapse All | Expand All

(-)a/C4/VirtualShelves/Page.pm (-4 / +20 lines)
Lines 237-243 sub shelfpage { Link Here
237
            # explicitly fetch this shelf
237
            # explicitly fetch this shelf
238
            my ($shelfnumber2,$shelfname,$owner,$category,$sorton) = GetShelf($shelfnumber);
238
            my ($shelfnumber2,$shelfname,$owner,$category,$sorton) = GetShelf($shelfnumber);
239
239
240
            $template->param( 'AllowOnShelfHolds' => C4::Context->preference('AllowOnShelfHolds') );
240
            $template->param(
241
                'AllowOnShelfHolds'     => C4::Context->preference('AllowOnShelfHolds'),
242
                'DisplayMultiPlaceHold' => C4::Context->preference('DisplayMultiPlaceHold'),
243
            );
241
            if (C4::Context->preference('TagsEnabled')) {
244
            if (C4::Context->preference('TagsEnabled')) {
242
                $template->param(TagsEnabled => 1);
245
                $template->param(TagsEnabled => 1);
243
                    foreach (qw(TagsShowOnList TagsInputOnList)) {
246
                    foreach (qw(TagsShowOnList TagsInputOnList)) {
Lines 253-261 sub shelfpage { Link Here
253
                for my $this_item (@$items) {
256
                for my $this_item (@$items) {
254
                    my $biblionumber = $this_item->{'biblionumber'};
257
                    my $biblionumber = $this_item->{'biblionumber'};
255
                    my $record = GetMarcBiblio($biblionumber);
258
                    my $record = GetMarcBiblio($biblionumber);
256
                    $this_item->{XSLTBloc} =
259
                    if (C4::Context->preference("OPACXSLTResultsDisplay") && $type eq 'opac') {
257
                        XSLTParse4Display($biblionumber, $record, "OPACXSLTResultsDisplay")
260
                        $this_item->{XSLTBloc} = XSLTParse4Display($biblionumber, $record, "OPACXSLTResultsDisplay");
258
                            if C4::Context->preference("OPACXSLTResultsDisplay") && $type eq 'opac';
261
                    } elsif (C4::Context->preference("XSLTResultsDisplay") && $type eq 'intranet') {
262
                        $this_item->{XSLTBloc} = XSLTParse4Display($biblionumber, $record, "XSLTResultsDisplay");
263
                    }
259
264
260
                    # the virtualshelfcontents table does not store these columns nor are they retrieved from the items
265
                    # the virtualshelfcontents table does not store these columns nor are they retrieved from the items
261
                    # and itemtypes tables, so I'm commenting them out for now to quiet the log -crn
266
                    # and itemtypes tables, so I'm commenting them out for now to quiet the log -crn
Lines 285-290 sub shelfpage { Link Here
285
                    }
290
                    }
286
291
287
                }
292
                }
293
                if($type eq 'intranet'){
294
                    # Build drop-down list for 'Add To:' menu...
295
                    my ($totalref, $pubshelves, $barshelves)=
296
                    C4::VirtualShelves::GetSomeShelfNames($loggedinuser,'COMBO',1);
297
                    $template->param(
298
                        addbarshelves     => $totalref->{bartotal},
299
                        addbarshelvesloop => $barshelves,
300
                        addpubshelves     => $totalref->{pubtotal},
301
                        addpubshelvesloop => $pubshelves,
302
                    );
303
                }
288
                push @paramsloop, { display => 'privateshelves' } if $category == 1;
304
                push @paramsloop, { display => 'privateshelves' } if $category == 1;
289
                $showadd = 1;
305
                $showadd = 1;
290
                my $i = 0;
306
                my $i = 0;
(-)a/koha-tmpl/intranet-tmpl/prog/en/css/addbiblio.css (-5 lines)
Lines 151-161 a.tagnum { Link Here
151
.yui-gf .yui-u {
151
.yui-gf .yui-u {
152
	width: 79.2%;
152
	width: 79.2%;
153
}
153
}
154
/* Class to be added to toolbar when it starts being fixed at the top of the screen*/
155
.floating {
156
	-webkit-box-shadow: 0px 3px 2px 0px rgba(0, 0, 0, .5);
157
	box-shadow: 0px 3px 2px 0px rgba(0, 0, 0, .5);
158
}
159
154
160
tr.active td {
155
tr.active td {
161
    background-color: #FFFFCC;
156
    background-color: #FFFFCC;
(-)a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css (+10 lines)
Lines 2414-2419 video { Link Here
2414
    background-position:-3px -166px;
2414
    background-position:-3px -166px;
2415
}
2415
}
2416
2416
2417
.icon-merge {
2418
    background-position:-48px -166px;
2419
}
2420
2417
#toolbar .btn,
2421
#toolbar .btn,
2418
#toolbar .dropdown-menu {
2422
#toolbar .dropdown-menu {
2419
    font-size: 13px;
2423
    font-size: 13px;
Lines 2548-2550 a.disabled { Link Here
2548
.modal-header .closebtn{margin-top:2px;}
2552
.modal-header .closebtn{margin-top:2px;}
2549
.closebtn{float:right;font-size:20px;font-weight:bold;line-height:20px;color:#000000;text-shadow:0 1px 0 #ffffff;opacity:0.2;filter:alpha(opacity=20);}.closebtn:hover{color:#000000;text-decoration:none;cursor:pointer;opacity:0.4;filter:alpha(opacity=40);}
2553
.closebtn{float:right;font-size:20px;font-weight:bold;line-height:20px;color:#000000;text-shadow:0 1px 0 #ffffff;opacity:0.2;filter:alpha(opacity=20);}.closebtn:hover{color:#000000;text-decoration:none;cursor:pointer;opacity:0.4;filter:alpha(opacity=40);}
2550
button.closebtn{padding:0;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;}
2554
button.closebtn{padding:0;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;}
2555
2556
/* Class to be added to toolbar when it starts being fixed at the top of the screen*/
2557
.floating {
2558
    -webkit-box-shadow: 0px 3px 2px 0px rgba(0, 0, 0, .5);
2559
    box-shadow: 0px 3px 2px 0px rgba(0, 0, 0, .5);
2560
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/js/basket.js (-15 / +15 lines)
Lines 153-169 function SelectAll(){ Link Here
153
    }
153
    }
154
}
154
}
155
155
156
function addMultiple(){
156
function addMultiple(biblist){
157
    var c_value = "";
157
    var c_value = "";
158
    if(document.bookbag_form.biblionumber.length > 0) {
158
    if(biblist.length > 0) {
159
        for (var i=0; i < document.bookbag_form.biblionumber.length; i++) {
159
        for (var i=0; i < biblist.length; i++) {
160
            if (document.bookbag_form.biblionumber[i].checked) {
160
            if (biblist[i].checked) {
161
                c_value = c_value + document.bookbag_form.biblionumber[i].value + "/";
161
                c_value = c_value + biblist[i].value + "/";
162
            }
162
            }
163
        }
163
        }
164
        addSelRecords(c_value);
164
        addSelRecords(c_value);
165
    } else {
165
    } else {
166
        c_value = c_value + document.bookbag_form.biblionumber.value + "/";
166
        c_value = c_value + biblist.value + "/";
167
        addSelRecords(c_value);
167
        addSelRecords(c_value);
168
    }
168
    }
169
}
169
}
Lines 403-421 function addSelToShelf() { Link Here
403
403
404
///  vShelfAdd()  builds url string for multiple-biblio adds.
404
///  vShelfAdd()  builds url string for multiple-biblio adds.
405
405
406
function vShelfAdd() {
406
function vShelfAdd(biblist) {
407
        bibs= new Array;
407
        bibs = new Array();
408
        if(document.bookbag_form.biblionumber.length > 0) {
408
        if(biblist.length > 0) {
409
                for (var i=0; i < document.bookbag_form.biblionumber.length; i++) {
409
                for (var i=0; i < biblist.length; i++) {
410
                        if (document.bookbag_form.biblionumber[i].checked) {
410
                        if (biblist[i].checked) {
411
                                bibs.push("biblionumber=" +  document.bookbag_form.biblionumber[i].value);
411
                                bibs.push("biblionumber=" +  biblist[i].value);
412
                        }
412
                        }
413
                }
413
                }
414
	    if (bibs.length == 0) { showListsUpdate(MSG_NO_RECORD_SELECTED); }
414
        if (bibs.length == 0) { showListsUpdate(MSG_NO_RECORD_SELECTED); }
415
            return bibs.join("&");
415
            return bibs.join("&");
416
        } else {
416
        } else {
417
            if (document.bookbag_form.biblionumber.checked) {
417
            if (biblist.checked) {
418
                return "biblionumber=" + document.bookbag_form.biblionumber.value;
418
                return "biblionumber=" + biblist.value;
419
            }
419
            }
420
        }
420
        }
421
}
421
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt (-7 / +9 lines)
Lines 30-54 function Dopop(link) { Link Here
30
        newin=window.open(link,'popup','width=500,height=500,toolbar=false,scrollbars=yes,resizeable=yes');
30
        newin=window.open(link,'popup','width=500,height=500,toolbar=false,scrollbars=yes,resizeable=yes');
31
}
31
}
32
function cartList(){
32
function cartList(){
33
    var checkboxes = $("#searchresults").find(":checkbox");
34
    var vshelf = vShelfAdd(checkboxes);
33
    if($("#addto").find("option:selected").attr("value") == "addtolist"){
35
    if($("#addto").find("option:selected").attr("value") == "addtolist"){
34
        var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
36
        var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
35
        if (vShelfAdd()) {
37
        if (vshelf) {
36
             Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?shelfnumber='+shelfnumber+'&confirm=1&' + vShelfAdd());
38
             Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?shelfnumber='+shelfnumber+'&confirm=1&' + vshelf);
37
        }
39
        }
38
        return false;
40
        return false;
39
    } else if($("#addto").find("option:selected").attr("value") == "newlist"){
41
    } else if($("#addto").find("option:selected").attr("value") == "newlist"){
40
        if (vShelfAdd()) {
42
        if (vshelf) {
41
            Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
43
            Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?newshelf=1&' + vshelf);
42
        }
44
        }
43
        return false;
45
        return false;
44
    } else if($("#addto").find("option:selected").attr("value") == "morelists"){
46
    } else if($("#addto").find("option:selected").attr("value") == "morelists"){
45
        if (vShelfAdd()) {
47
        if (vshelf) {
46
            Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?' + vShelfAdd());
48
            Dopop('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?' + vshelf);
47
        }
49
        }
48
        return false;
50
        return false;
49
    }
51
    }
50
    if($("#addto").find("option:selected").attr("value") == "addtocart"){
52
    if($("#addto").find("option:selected").attr("value") == "addtocart"){
51
        addMultiple();
53
        addMultiple(checkboxes);
52
        return false;
54
        return false;
53
    }
55
    }
54
}
56
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt (-32 / +148 lines)
Lines 1-16 Link Here
1
[% INCLUDE 'doc-head-open.inc' %]
1
[% INCLUDE 'doc-head-open.inc' %]
2
<title>Koha &rsaquo; [% IF ( viewshelf ) %]Lists &rsaquo; Contents of [% shelfname | html %][% ELSE %]Lists[% END %][% IF ( shelves ) %] &rsaquo; Create new list[% END %][% IF ( edit ) %] &rsaquo; Edit list [% shelfname | html %][% END %]</title>
2
<title>Koha &rsaquo; [% IF ( viewshelf ) %]Lists &rsaquo; Contents of [% shelfname | html %][% ELSE %]Lists[% END %][% IF ( shelves ) %] &rsaquo; Create new list[% END %][% IF ( edit ) %] &rsaquo; Edit list [% shelfname | html %][% END %]</title>
3
[% INCLUDE 'doc-head-close.inc' %]
3
[% INCLUDE 'doc-head-close.inc' %]
4
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
4
[% IF ( viewshelf ) %]
5
    <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
6
    <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.fixFloat.js"></script>
7
[% END %]
5
<script type="text/javascript">
8
<script type="text/javascript">
6
//<![CDATA[ 
9
//<![CDATA[ 
7
10
8
var MSG_NO_ITEM_SELECTED = _("Nothing is selected.");
11
var MSG_NO_ITEM_SELECTED = _("Nothing is selected.");
9
var MSG_REMOVE_FROM_LIST = _("Are you sure you want to remove these records from the shelf?");
12
var MSG_REMOVE_FROM_LIST = _("Are you sure you want to remove these records from the shelf?");
10
var MSG_CONFIRM_DELETE_LIST = _("Are you sure you want to remove this list?");
13
var MSG_CONFIRM_DELETE_LIST = _("Are you sure you want to remove this list?");
11
14
[% IF ( viewshelf ) %]
12
$(document).ready(function(){
15
$(document).ready(function(){
13
	$("#addbarcode").focus();
16
    [% IF ( itemsloop ) %]$('#searchheader').fixFloat();[% END %]
14
    $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Clear all")+"<\/a>");
17
    $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Clear all")+"<\/a>");
15
    $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Select all")+"<\/a>");
18
    $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Select all")+"<\/a>");
16
    $("#CheckAll").click(function(){
19
    $("#CheckAll").click(function(){
Lines 21-28 $(document).ready(function(){ Link Here
21
        $(".checkboxed").unCheckCheckboxes();
24
        $(".checkboxed").unCheckCheckboxes();
22
        return false;
25
        return false;
23
    });
26
    });
24
    $("#placehold").show();
27
    $(".placehold").on("click",function(e){
28
        placeHold();
29
        e.preventDefault();
30
    });
31
32
    $(".addtocart").show();
33
    var param1 = "| <label for=\"addto\">"+_("Add to:")+"<\/label><select name=\"addto\" id=\"addto\"><option value=\"\"><\/option>";
34
    [% IF ( intranetbookbag ) %]
35
         param1 += "<option value=\"addtocart\">"+_("Cart")+"<\/option>";
36
    [% END %]
37
    [% IF ( virtualshelves ) %]
38
        [% IF ( addbarshelves ) %]
39
            param1 += "<optgroup label=\""+_("Your lists:")+"\">";
40
            [% FOREACH addbarshelvesloo IN addbarshelvesloop %]
41
                [% IF ( shelfnumber != addbarshelvesloo.shelfnumber ) %]
42
                    param1 += "<option id=\"s[% addbarshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addbarshelvesloo.shelfname |html %]<\/option>";
43
                [% END %]
44
            [% END %]
45
            param1 += "<\/optgroup>";
46
        [% END %]
47
        [% IF ( addpubshelves ) %]
48
            param1 += "<optgroup label=\""+_("Public lists:")+"\">";
49
            [% FOREACH addpubshelvesloo IN addpubshelvesloop %]
50
                [% IF ( shelfnumber != addpubshelvesloo.shelfnumber ) %]
51
                    param1 += "<option id=\"s[% addpubshelvesloo.shelfnumber %]\" value=\"addtolist\">[% addpubshelvesloo.shelfname |html %]<\/option>";
52
                [% END %]
53
            [% END %]
54
            param1 += "<\/optgroup>";
55
        [% END %]
56
        [% IF ( ( addbarshelvesloop && addbarshelvesloop.size > 9 ) || (addpubshelvesloop && addpubshelvesloop.size > 9 )) %]
57
            param1 += "<option value=\"morelists\">[ "+_("More lists")+" ]<\/option>";
58
        [% END %]
59
        param1 +="<option value=\"newlist\">"+_("[ New list ]")+"<\/option>"
60
    [% END %]
61
    param1 += "<\/select> <input id=\"cartsubmit\" type=\"submit\" class=\"submit\" value=\""+_("Save")+"\" />";
62
    $("span.addto").html(param1);
63
    $("#addto").change(function(){
64
        cartList();
65
    });
66
    $(".addto").find("input:submit").click(function(e){
67
        e.preventDefault();
68
        cartList();
69
    });
70
    $("#selection_ops").show();
71
    $(".merge-items").on("click",function(e){
72
        e.preventDefault();
73
        MergeItems();
74
    });
75
    $(".list-remove").on("click",function(e){
76
        if($(".selection").filter(":checked").length > 0){
77
            return confirm(MSG_REMOVE_FROM_LIST);
78
        } else {
79
            alert(MSG_NO_ITEM_SELECTED);
80
            e.preventDefault();
81
        }
82
    });
25
});
83
});
84
[% END %]
26
85
27
	function confirmDelete(message){
86
	function confirmDelete(message){
28
		if (window.confirm(message)) {
87
		if (window.confirm(message)) {
Lines 75-81 $(document).ready(function(){ Link Here
75
        }
134
        }
76
        return true;
135
        return true;
77
    }
136
    }
78
    
137
79
function placeHold () {
138
function placeHold () {
80
    var checkedItems = $(".selection:checked");
139
    var checkedItems = $(".selection:checked");
81
    if ($(checkedItems).size() == 0) {
140
    if ($(checkedItems).size() == 0) {
Lines 98-104 function placeHold () { Link Here
98
		var alertString2;
157
		var alertString2;
99
158
100
	    if($("#shelfname").val() == ""){
159
	    if($("#shelfname").val() == ""){
101
			_alertString += _("- You must enter a List Name") + "\n";
160
            _alertString += "- "+_("You must enter a List Name") + "\n";
102
		}
161
		}
103
162
104
		if (_alertString.length==0) {
163
		if (_alertString.length==0) {
Lines 110-115 function placeHold () { Link Here
110
			alert(alertString2);
169
			alert(alertString2);
111
		}
170
		}
112
	}
171
	}
172
    function cartList(){
173
        var checkboxes = $("#searchresults").find(":checkbox");
174
        var vshelf = vShelfAdd(checkboxes);
175
        if($("#addto").find("option:selected").attr("value") == "addtolist"){
176
            var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
177
            if (vshelf) {
178
                 openWindow('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?shelfnumber='+shelfnumber+'&confirm=1&' + vshelf,'popup',500,500);
179
            }
180
            return false;
181
        } else if($("#addto").find("option:selected").attr("value") == "newlist"){
182
            if (vshelf) {
183
                openWindow('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?newshelf=1&' + vshelf,'popup',500,500);
184
            }
185
            return false;
186
        } else if($("#addto").find("option:selected").attr("value") == "morelists"){
187
            if (vshelf) {
188
                openWindow('/cgi-bin/koha/virtualshelves/addbybiblionumber.pl?' + vshelf,'popup',500,500);
189
            }
190
            return false;
191
        }
192
        if($("#addto").find("option:selected").attr("value") == "addtocart"){
193
            addMultiple(checkboxes);
194
            return false;
195
        }
196
    }
113
//]]>
197
//]]>
114
</script>
198
</script>
115
</head>
199
</head>
Lines 147-153 function placeHold () { Link Here
147
231
148
[% IF ( viewshelf ) %]&rsaquo; Contents of <i>[% shelfname | html %]</i>[% END %][% IF ( shelves ) %] &rsaquo; Create new list[% END %][% IF ( edit ) %] &rsaquo; Edit list <i>[% shelfname | html %]</i>[% END %]</div>
232
[% IF ( viewshelf ) %]&rsaquo; Contents of <i>[% shelfname | html %]</i>[% END %][% IF ( shelves ) %] &rsaquo; Create new list[% END %][% IF ( edit ) %] &rsaquo; Edit list <i>[% shelfname | html %]</i>[% END %]</div>
149
233
150
<div id="doc" class="yui-t7">
234
<div id="doc2" class="yui-t7">
151
 <div id="bd">
235
 <div id="bd">
152
  <div id="yui-main">
236
  <div id="yui-main">
153
   <div class="yui-g">[% INCLUDE 'virtualshelves-toolbar.inc' %]
237
   <div class="yui-g">[% INCLUDE 'virtualshelves-toolbar.inc' %]
Lines 193-211 function placeHold () { Link Here
193
   <div class="yui-g">
277
   <div class="yui-g">
194
    [% IF ( itemsloop ) %]
278
    [% IF ( itemsloop ) %]
195
279
196
	<form action="/cgi-bin/koha/virtualshelves/shelves.pl" method="post" class="checkboxed">
280
    <h3>Contents of <i>[% shelfname | html %]</i></h3>
281
    <div class="pages">[% pagination_bar %]</div>
282
    <form action="/cgi-bin/koha/virtualshelves/shelves.pl" name="listform" method="post" class="checkboxed">
197
        <input type="hidden" name="viewshelf" value="[% shelfnumber %]" />
283
        <input type="hidden" name="viewshelf" value="[% shelfnumber %]" />
198
        <input type="hidden" name="modifyshelfcontents" value="1" />
284
        <input type="hidden" name="modifyshelfcontents" value="1" />
199
 <fieldset>
285
200
  <legend>Contents of <i>[% shelfname | html %]</i></legend>
286
<div id="searchheader">
201
   
287
    [% IF ( itemsloop ) %]
202
 [% IF ( itemsloop ) %]
288
        <div id="selection_ops"><span class="checkall"></span> |
203
     <p><span class="checkall"></span> |
289
        <span class="clearall"></span>
204
     <span class="clearall"></span></p>
290
205
 [% END %]
291
        <span class="addto">| </span>
206
	
292
        &nbsp;
207
 <div class="pages">[% pagination_bar %]</div>
293
        [% IF ( CAN_user_reserveforothers && DisplayMultiPlaceHold ) %]
208
    <table>
294
            <div class="btn-group"><button class="btn btn-mini placehold"><i class="icon-hold"></i> Place hold</button></div>
295
        [% END %]
296
        [% IF ( allowremovingitems ) %]
297
            <div class="btn-group"><button type="submit" class="btn btn-mini list-remove"><i class="icon-remove-sign"></i> Remove selected</button></div>
298
        [% END %]
299
        [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]<div class="btn-group"><button type="submit" class="btn btn-mini merge-items"><i class="icon-merge"></i> Merge selected</button></div>[% END %]
300
        </div>
301
    [% END %]
302
</div>
303
304
    <table id="searchresults">
209
            <tr>
305
            <tr>
210
                [% IF ( itemsloop ) %]<th class="checkall">&nbsp;</th>[% END %]
306
                [% IF ( itemsloop ) %]<th class="checkall">&nbsp;</th>[% END %]
211
                [% UNLESS ( item_level_itypes ) %]<th>Item type</th>[% END %]
307
                [% UNLESS ( item_level_itypes ) %]<th>Item type</th>[% END %]
Lines 213-219 function placeHold () { Link Here
213
                <th>Author</th>
309
                <th>Author</th>
214
                <th>Date added</th>
310
                <th>Date added</th>
215
                <th>Call number</th>
311
                <th>Call number</th>
216
                <th>&nbsp;</th>
217
            </tr>
312
            </tr>
218
		[% FOREACH itemsloo IN itemsloop %]
313
		[% FOREACH itemsloo IN itemsloop %]
219
			[% UNLESS ( loop.odd ) %]
314
			[% UNLESS ( loop.odd ) %]
Lines 235-265 function placeHold () { Link Here
235
                [% UNLESS ( noItemTypeImages || !itemsloo.imageurl ) %]<img src="[% itemsloo.imageurl %]" alt="[% itemsloo.description %]" title="[% itemsloo.description %]" />[% END %][% itemsloo.description %]
330
                [% UNLESS ( noItemTypeImages || !itemsloo.imageurl ) %]<img src="[% itemsloo.imageurl %]" alt="[% itemsloo.description %]" title="[% itemsloo.description %]" />[% END %][% itemsloo.description %]
236
			</td>[% END %]
331
			</td>[% END %]
237
			<td>
332
			<td>
238
			[% INCLUDE 'biblio-default-view.inc' biblionumber = itemsloo.biblionumber %]
333
                [% IF ( itemsloo.XSLTBloc ) %]
239
			[% itemsloo.title |html %][% FOREACH subtitl IN itemsloo.subtitle %] [% subtitl.subfield %][% END %]</a>
334
                    [% itemsloo.XSLTBloc %]
335
                [% ELSE %]
336
                    [% INCLUDE 'biblio-default-view.inc' biblionumber = itemsloo.biblionumber %]
337
                    [% itemsloo.title |html %][% FOREACH subtitl IN itemsloo.subtitle %] [% subtitl.subfield %][% END %]</a>
338
                [% END %]
339
                    <p class="hold">
340
                        [% IF ( itemsloo.norequests ) %]
341
                            <span class="noholdstext">No holds allowed</span>
342
                        [% ELSE %]
343
                            <a id="reserve_[% itemsloo.biblionumber %]" href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% itemsloo.biblionumber %]">Holds</a>
344
                                [% IF ( holdfor ) %] <span class="holdforlink">| <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% itemsloo.biblionumber %]&amp;findborrower=[% holdfor_cardnumber %]">Place hold for [% holdfor_firstname %] [% holdfor_surname %] ([% holdfor_cardnumber %])</a></span>[% END %]
345
                        [% END %]
346
                        [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]
347
                            | <a href="/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=[% itemsloo.biblionumber %]">Edit record</a>
348
                        [% END %]
349
                        [% IF ( CAN_user_editcatalogue_edit_items ) %]
350
                            | <a href="/cgi-bin/koha/cataloguing/additem.pl?biblionumber=[% itemsloo.biblionumber %]">Edit items</a>
351
                        [% END %]
352
                    </p>
240
			</td>
353
			</td>
241
			<td>[% itemsloo.author %]</td>
354
			<td>[% itemsloo.author %]</td>
242
			<td>[% itemsloo.dateadded %]</td>
355
			<td>[% itemsloo.dateadded %]</td>
243
			<td>
356
			<td>
244
                [% FOREACH result IN itemsloo.ITEM_RESULTS %][% result.itemcallnumber %][% UNLESS loop.last %], [% END %][% END %]
357
                <ul>
358
                [% FOREACH result IN itemsloo.ITEM_RESULTS %]
359
                    <li>[% result.holdingbranch %] [% IF ( result.location_intranet ) %] ([% result.location_intranet %]) [% END %]
360
                        [% IF ( result.itemcallnumber ) %]
361
                            [<a href="/cgi-bin/koha/catalogue/search.pl?idx=callnum&amp;q=[% result.itemcallnumber |url %]">[% result.itemcallnumber %]</a>]
362
                        [% END %]
363
                    </li>
364
                [% END %]
365
                </ul>
245
            </td>
366
            </td>
246
            <td>
247
			[% UNLESS ( itemsloo.notforloan ) %]
248
			<a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% itemsloo.biblionumber %]">Holds</a>
249
			[% END %]
250
			</td>
251
			</tr>
367
			</tr>
252
		[% END %]<!-- /itemsloop -->
368
		[% END %]<!-- /itemsloop -->
253
    </table><fieldset class="action">
369
    </table><fieldset class="action">
254
        [% IF ( itemsloop ) %]
370
        [% IF ( itemsloop ) %]
255
            <input type="button" id="placehold" style="display:none" onclick="placeHold(); return false;" value="Place holds" />
371
            [% IF ( CAN_user_reserveforothers && DisplayMultiPlaceHold ) %]<input type="button" class="placehold" value="Place hold" />[% END %]
256
            [% IF ( allowremovingitems ) %]<input type="submit" value="Remove selected records" onclick="return confirm(MSG_REMOVE_FROM_LIST);" />[% END %]
372
            [% IF ( allowremovingitems ) %]<input type="submit" value="Remove selected records" class="
257
            <input type="submit" value="Merge selected records" onclick="return MergeItems();" />
373
            list-remove" />[% END %]
374
            [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]<input type="submit" value="Merge selected records" class="merge-items" />[% END %]
258
        [% END %]
375
        [% END %]
259
 </fieldset>
376
 </fieldset>
260
 </fieldset>
261
 
262
</form>
377
</form>
378
263
	[% END %]
379
	[% END %]
264
   </div>
380
   </div>
265
[% END %]<!-- /viewshelf -->
381
[% END %]<!-- /viewshelf -->

Return to bug 9757