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

(-)a/Koha/Template/Plugin/ExtendedAttributeTypes.pm (-1 / +4 lines)
Lines 33-39 sub all { Link Here
33
33
34
sub codes {
34
sub codes {
35
    my ( $self, $params ) = @_;
35
    my ( $self, $params ) = @_;
36
    return Koha::Patron::Attribute::Types->search($params)->get_column('code');
36
37
    my @codes = Koha::Patron::Attribute::Types->search($params)->get_column('code');
38
39
    return \@codes;
37
}
40
}
38
41
39
1;
42
1;
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc (-1 / +1 lines)
Lines 280-286 Link Here
280
        }, {});
280
        }, {});
281
281
282
        [% IF Koha.Preference('ExtendedPatronAttributes') %]
282
        [% IF Koha.Preference('ExtendedPatronAttributes') %]
283
            [% SET extended_attribute_types = [ ExtendedAttributeTypes.codes( staff_searchable => 1, searched_by_default => 1 ) ] %]
283
            [% SET extended_attribute_types = ExtendedAttributeTypes.codes( staff_searchable => 1, searched_by_default => 1 ) %]
284
            var extended_attribute_types = [% To.json(extended_attribute_types || []) | $raw %];
284
            var extended_attribute_types = [% To.json(extended_attribute_types || []) | $raw %];
285
        [% END %]
285
        [% END %]
286
286
(-)a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js (-2 / +1 lines)
Lines 860-866 function buildPatronSearchQuery(term, options) { Link Here
860
    if (
860
    if (
861
        typeof options !== "undefined" &&
861
        typeof options !== "undefined" &&
862
        ((options.search_fields == "standard" &&
862
        ((options.search_fields == "standard" &&
863
            options.extended_attribute_types) ||
863
            options.extended_attribute_types.length > 0) ||
864
            searched_attribute_fields.length > 0) &&
864
            searched_attribute_fields.length > 0) &&
865
        extendedPatronAttributes
865
        extendedPatronAttributes
866
    ) {
866
    ) {
867
- 

Return to bug 36025