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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/js_includes.inc (-2 / +2 lines)
Lines 98-108 Link Here
98
                        var cardnumber = "";
98
                        var cardnumber = "";
99
                        if( item.cardnumber != "" ){
99
                        if( item.cardnumber != "" ){
100
                            // Display card number in parentheses if it exists
100
                            // Display card number in parentheses if it exists
101
                            cardnumber = " (" + item.cardnumber + ") ";
101
                            cardnumber = " (" + ( item.cardnumber ? item.surname.escapeHtml() : "" ) + ") ";
102
                        }
102
                        }
103
                        return $( "<li></li>" )
103
                        return $( "<li></li>" )
104
                        .data( "ui-autocomplete-item", item )
104
                        .data( "ui-autocomplete-item", item )
105
                        .append( "<a href=\"" + item.link + "\">" + item.surname + ", " + item.firstname + cardnumber + " <small>" + item.dateofbirth + " " + item.address + " " + item.city + " " + item.zipcode + " " + item.country + "</small></a>" )
105
                        .append( "<a href=\"" + item.link + "\">" + ( item.surname ? item.surname.escapeHtml() : "" ) + ", " + ( item.firstname ? item.firstname.escapeHtml : "" ) + ( cardnumber ? cardnumber.escapeHtml() : "" ) + " <small>" + ( item.dateofbirth ? item.dateofbirth.escapeHtml() : "" ) + " " + ( item.address ? item.address.escapeHtml() : "" ) + " " + ( item.city ? item.city.escapeHtml() : "" ) + " " + ( item.zipcode ? item.zipcode.escapeHtml() : "" ) + " " + ( item.country ? item.country.escapeHtml() : "" ) + "</small></a>" )
106
                        .appendTo( ul );
106
                        .appendTo( ul );
107
                    };
107
                    };
108
                }
108
                }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/request-article.tt (-4 / +17 lines)
Lines 323-332 Link Here
323
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
323
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
324
                    return $( "<li></li>" )
324
                    return $( "<li></li>" )
325
                    .data( "ui-autocomplete-item", item )
325
                    .data( "ui-autocomplete-item", item )
326
                    .append( "<a>" + item.surname + ", " + item.firstname +
326
                    .append(
327
                             " (" + item.cardnumber + ") <small>" + item.address +
327
                        "<a>"
328
                             " " + item.city + " " + item.zipcode + " " +
328
                            + ( item.surname ? item.surname.escapeHtml() : "" )
329
                             item.country + "</small></a>" )
329
                            + ", "
330
                            + ( item.firstname ? item.firstname.escapeHtml() : "" )
331
                            + " (" + ( item.cardnumber ? item.cardnumber.escapeHtml() : "" ) + ")"
332
                            + " "
333
                            + "<small>"
334
                                + ( item.address ? item.address.escapeHtml() : "" )
335
                                + " "
336
                                + ( item.city ? item.city.escapeHtml() : "" )
337
                                + " "
338
                                + ( item.zipcode ? item.zipcode.escapeHtml() : "" )
339
                                + " "
340
                                + ( item.country ? item.country.escapeHtml() : "" )
341
                            + "</small>"
342
                        + "</a>" )
330
                    .appendTo( ul );
343
                    .appendTo( ul );
331
                };
344
                };
332
            }
345
            }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course.tt (-2 / +18 lines)
Lines 169-175 Link Here
169
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
169
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
170
                    return $( "<li></li>" )
170
                    return $( "<li></li>" )
171
                    .data( "ui-autocomplete-item", item )
171
                    .data( "ui-autocomplete-item", item )
172
                    .append( "<a>" + item.surname + ", " + item.firstname + " (" + item.cardnumber + ") <small>" + item.address + " " + item.city + " " + item.zipcode + " " + item.country + "</small></a>" )
172
                    .append(
173
                        "<a>"
174
                            + ( item.surname ? item.surname.escapeHtml() : "" )
175
                            + ", "
176
                            + ( item.firstname ? item.firstname.escapeHtml() : "" )
177
                            + " (" + ( item.cardnumber ? item.cardnumber.escapeHtml() : "" ) + ")"
178
                            + " "
179
                            + "<small>"
180
                                + ( item.address ? item.address.escapeHtml() : "" )
181
                                + " "
182
                                + ( item.city ? item.city.escapeHtml() : "" )
183
                                + " "
184
                                + ( item.zipcode ? item.zipcode.escapeHtml() : "" )
185
                                + " "
186
                                + ( item.country ? item.country.escapeHtml() : "" )
187
                            + "</small>"
188
                        + "</a>" )
173
                    .appendTo( ul );
189
                    .appendTo( ul );
174
                };
190
                };
175
191
Lines 186-192 Link Here
186
            });
202
            });
187
203
188
            function AddInstructor( name, borrowernumber ) {
204
            function AddInstructor( name, borrowernumber ) {
189
                div = "<div class='instructor_line' id='borrower_" + borrowernumber + "'>" + name + " ( <a href='#' class='removeInstructor'><i class='fa fa-trash'></i> " + _("Remove")+ " </a> ) <input type='hidden' name='instructors' value='" + borrowernumber + "' /></div>";
205
                div = "<div class='instructor_line' id='borrower_" + borrowernumber + "'>" + ( name ? name.escapeHtml() : "" ) + " ( <a href='#' class='removeInstructor'><i class='fa fa-trash'></i> " + _("Remove")+ " </a> ) <input type='hidden' name='instructors' value='" + borrowernumber + "' /></div>";
190
                $('#instructors').append( div );
206
                $('#instructors').append( div );
191
207
192
                $('#find_instructor').val('').focus();
208
                $('#find_instructor').val('').focus();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt (-5 / +17 lines)
Lines 902-911 Link Here
902
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
902
                .data( "ui-autocomplete" )._renderItem = function( ul, item ) {
903
                    return $( "<li></li>" )
903
                    return $( "<li></li>" )
904
                    .data( "ui-autocomplete-item", item )
904
                    .data( "ui-autocomplete-item", item )
905
                    .append( "<a>" + item.surname + ", " + item.firstname +
905
                    .append(
906
                             " (" + item.cardnumber + ") <small>" + item.address +
906
                        "<a>"
907
                             " " + item.city + " " + item.zipcode + " " +
907
                            + ( item.surname ? item.surname.escapeHtml() : "" )
908
                             item.country + "</small></a>" )
908
                            + ", "
909
                            + ( item.firstname ? item.firstname.escapeHtml() : "" )
910
                            + " (" + ( item.cardnumber ? item.cardnumber.escapeHtml() : "" ) + ")"
911
                            + " "
912
                            + "<small>"
913
                                + ( item.address ? item.address.escapeHtml() : "" )
914
                                + " "
915
                                + ( item.city ? item.city.escapeHtml() : "" )
916
                                + " "
917
                                + ( item.zipcode ? item.zipcode.escapeHtml() : "" )
918
                                + " "
919
                                + ( item.country ? item.country.escapeHtml() : "" )
920
                            + "</small>"
921
                        + "</a>" )
909
                    .appendTo( ul );
922
                    .appendTo( ul );
910
                };
923
                };
911
                [% END %]
924
                [% END %]
912
- 

Return to bug 26592