Lines 267-273
sub raw_elasticsearch_mappings {
Link Here
|
267 |
{ search_field_id => $search_field->id }, |
267 |
{ search_field_id => $search_field->id }, |
268 |
{ |
268 |
{ |
269 |
join => 'search_marc_map', |
269 |
join => 'search_marc_map', |
270 |
order_by => { -asc => 'search_marc_map.marc_field' } |
270 |
order_by => { -asc => ['search_marc_map.marc_type','search_marc_map.marc_field'] } |
271 |
} |
271 |
} |
272 |
); |
272 |
); |
273 |
|
273 |
|
Lines 279-286
sub raw_elasticsearch_mappings {
Link Here
|
279 |
|
279 |
|
280 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{label} = $search_field->label; |
280 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{label} = $search_field->label; |
281 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{type} = $search_field->type; |
281 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{type} = $search_field->type; |
282 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{facet_order} = $search_field->facet_order; |
282 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{facet_order} = $search_field->facet_order if defined $search_field->facet_order; |
283 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{weight} = $search_field->weight || undef; |
283 |
$mappings->{ $marc_map->index_name }{ $search_field->name }{weight} = $search_field->weight if defined $search_field->weight; |
284 |
|
284 |
|
285 |
push (@{ $mappings->{ $marc_map->index_name }{ $search_field->name }{mappings} }, |
285 |
push (@{ $mappings->{ $marc_map->index_name }{ $search_field->name }{mappings} }, |
286 |
{ |
286 |
{ |