|
Lines 86-91
sub search {
Link Here
|
| 86 |
my $params = $self->get_elasticsearch_params(); |
86 |
my $params = $self->get_elasticsearch_params(); |
| 87 |
# 20 is the default number of results per page |
87 |
# 20 is the default number of results per page |
| 88 |
$query->{size} = $count || 20; |
88 |
$query->{size} = $count || 20; |
|
|
89 |
|
| 90 |
$query->{aggregations}{author}{terms}{size} = $query->{aggregations}{ln}{terms}{size} = |
| 91 |
$query->{aggregations}{ccode}{terms}{size} = $query->{aggregations}{'title-series'}{terms}{size} = |
| 92 |
$query->{aggregations}{holdingbranch}{terms}{size} = $query->{aggregations}{itype}{terms}{size} = |
| 93 |
$query->{aggregations}{subject}{terms}{size} = $query->{aggregations}{'su-geo'}{terms}{size} = |
| 94 |
$query->{aggregations}{location}{terms}{size} = 50; |
| 95 |
|
| 89 |
# ES doesn't want pages, it wants a record to start from. |
96 |
# ES doesn't want pages, it wants a record to start from. |
| 90 |
if (exists $options{offset}) { |
97 |
if (exists $options{offset}) { |
| 91 |
$query->{from} = $options{offset}; |
98 |
$query->{from} = $options{offset}; |
| 92 |
- |
|
|