Jarn / collective.solr

9 stars 1 forks source link

Orphan parameter in Batch() hides results #11

Closed reinhardt closed 2 years ago

reinhardt commented 12 years ago

When Batch() is called with orphan=n (e.g. orphan=1 in search.pt) and the query yields n more results than a multiple of _bsize, the n results are effectively hidden. Batch tries to integrate the last n results into the last but one batch page, but since collective.solr only gets _bstart and _bsize and does not know about the orphan parameter, these results all have a None value and are not shown, yet the batch navigation drops the last page that would contain them. Manually adding something like ?b_start:int=10 actually shows the results.

As a side note: I found a doctest (tests/search.txt) that specifically tests whether the last batch page is dropped, but it should probably also check whether all results are displayed.

reinhardt commented 2 years ago

Probably obsolete by now.