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

(-)a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js (+11 lines)
Lines 130-135 $(document).ready(function() { Link Here
130
            }, "json")
130
            }, "json")
131
        });
131
        });
132
132
133
        $(".confirm:checked:visible").each(function() {
134
            itemnumber = $(this).val();
135
            id = "#checkin_" + itemnumber;
136
            materials = $(this).data('materials');
137
138
            $(this).replaceWith("<span class='confirm' id='checkin_" + itemnumber + "'>Confirm (<span>" + materials + "</span>): <input type='checkbox' class='checkin' name='checkin' value='" + itemnumber +"'></input></span>");
139
            $(id).parent().parent().addClass('warn');
140
        });
141
133
        $(".renew:checked:visible").each(function() {
142
        $(".renew:checked:visible").each(function() {
134
            var override_limit = $("#override_limit").is(':checked') ? 1 : 0;
143
            var override_limit = $("#override_limit").is(':checked') ? 1 : 0;
135
144
Lines 543-548 $(document).ready(function() { Link Here
543
                    "mDataProp": function ( oObj ) {
552
                    "mDataProp": function ( oObj ) {
544
                        if ( oObj.can_renew_error == "on_reserve" ) {
553
                        if ( oObj.can_renew_error == "on_reserve" ) {
545
                            return "<a href='/cgi-bin/koha/reserve/request.pl?biblionumber=" + oObj.biblionumber + "'>" + ON_HOLD + "</a>";
554
                            return "<a href='/cgi-bin/koha/reserve/request.pl?biblionumber=" + oObj.biblionumber + "'>" + ON_HOLD + "</a>";
555
                        } else if ( oObj.materials ) {
556
                            return "<input type='checkbox' class='confirm' id='confirm_" + oObj.itemnumber + "' name='confirm' value='" + oObj.itemnumber + "' data-materials='" + oObj.materials.escapeHtml() + "'></input>";
546
                        } else {
557
                        } else {
547
                            return "<input type='checkbox' class='checkin' id='checkin_" + oObj.itemnumber + "' name='checkin' value='" + oObj.itemnumber +"'></input>";
558
                            return "<input type='checkbox' class='checkin' id='checkin_" + oObj.itemnumber + "' name='checkin' value='" + oObj.itemnumber +"'></input>";
548
                        }
559
                        }
(-)a/svc/checkouts (-1 / +7 lines)
Lines 104-109 my $sql = ' Link Here
104
        items.damaged,
104
        items.damaged,
105
        items.location,
105
        items.location,
106
        items.enumchron,
106
        items.enumchron,
107
        items.materials,
107
108
108
        DATEDIFF( issues.issuedate, CURRENT_DATE() ) AS not_issued_today,
109
        DATEDIFF( issues.issuedate, CURRENT_DATE() ) AS not_issued_today,
109
110
Lines 186-191 while ( my $c = $sth->fetchrow_hashref() ) { Link Here
186
        my $av = Koha::AuthorisedValues->search({ category => 'DAMAGED', authorised_value => $c->{damaged} });
187
        my $av = Koha::AuthorisedValues->search({ category => 'DAMAGED', authorised_value => $c->{damaged} });
187
        $damaged = $av->count ? $av->next->lib : '';
188
        $damaged = $av->count ? $av->next->lib : '';
188
    }
189
    }
190
    my $materials;
191
    if ( $c->{materials} ) {
192
        my $descriptions = Koha::AuthorisedValues->get_description_by_koha_field({frameworkcode => '', kohafield =>'items.materials', authorised_value => $c->{materials} });
193
        $materials = $descriptions->{lib} // $c->{materials};
194
    }
189
    my @subtitles = split(/ \| /, $c->{'subtitle'} // '' );
195
    my @subtitles = split(/ \| /, $c->{'subtitle'} // '' );
190
    my $checkout = {
196
    my $checkout = {
191
        DT_RowId             => $c->{itemnumber} . '-' . $c->{borrowernumber},
197
        DT_RowId             => $c->{itemnumber} . '-' . $c->{borrowernumber},
Lines 248-253 while ( my $c = $sth->fetchrow_hashref() ) { Link Here
248
        lost    => $lost,
254
        lost    => $lost,
249
        claims_returned => $claims_returned,
255
        claims_returned => $claims_returned,
250
        damaged => $damaged,
256
        damaged => $damaged,
257
        materials => $materials,
251
        borrower => {
258
        borrower => {
252
            surname    => $c->{surname},
259
            surname    => $c->{surname},
253
            firstname  => $c->{firstname},
260
            firstname  => $c->{firstname},
254
- 

Return to bug 25261