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

(-)a/Koha/SearchEngine/Elasticsearch.pm (-3 / +9 lines)
Lines 260-269 sub raw_elasticsearch_mappings { Link Here
260
    my $mappings = {};
260
    my $mappings = {};
261
    while ( my $search_field = $search_fields->next ) {
261
    while ( my $search_field = $search_fields->next ) {
262
262
263
        my $marc_to_fields = $schema->resultset('SearchMarcToField')->search( { search_field_id => $search_field->id } );
263
        my $marc_to_fields = $schema->resultset('SearchMarcToField')->search(
264
            { search_field_id => $search_field->id },
265
            {
266
                join     => 'search_marc_map',
267
                order_by => { -asc => 'search_marc_map.marc_field' }
268
            }
269
        );
264
270
265
        while ( my $marc_to_field = $marc_to_fields->next ) {
271
        while ( my $marc_to_field = $marc_to_fields->next ) {
266
            my $marc_map = Koha::SearchMarcMaps->find( $marc_to_field->search_marc_map_id );
272
273
            my $marc_map = $marc_to_field->search_marc_map;
267
274
268
            next if $marc_type && $marc_map->marc_type ne $marc_type;
275
            next if $marc_type && $marc_map->marc_type ne $marc_type;
269
276
270
- 

Return to bug 23204