Bug 31668 - Avoid displaying nothing in facet
Summary: Avoid displaying nothing in facet
Status: RESOLVED DUPLICATE of bug 29561
Alias: None
Product: Koha
Classification: Unclassified
Component: Searching (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Alexis Ripetti
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-10-03 10:37 UTC by Nick Clemens (kidclamp)
Modified: 2022-10-12 13:13 UTC (History)
0 users

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 31668: Avoid displaying nothing in facet (4.36 KB, patch)
2022-10-03 10:39 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Clemens (kidclamp) 2022-10-03 10:37:22 UTC
Adding a way to avoid displaying nothing in facet for opac and client staff when using elasticsearch as SearchEngine.

Test plan:
1) Do a search, like 'a'
2) Look in the bottom of the sidebar on the left and see that there is an empty language
Comment 1 Nick Clemens (kidclamp) 2022-10-03 10:39:56 UTC
Created attachment 141245 [details] [review]
Bug 31668: Avoid displaying nothing in facet

This patch displays 'No information provided' if a facet value/description cannot be found,
rather than displaying an empty/hidden facet

Test plan:
1) Do a search, like 'a'
2) Look in the bottom of the sidebar on the left and see that there is an empty language
3) Apply patch
4) Update database
5) Do the same research
6) See that there is now "No information provided"

Signed-off-by: Alexis Ripetti <alexis.ripetti@inLibro.com>
Comment 2 Katrin Fischer 2022-10-08 11:10:01 UTC
At the moment I believe this is not fully functional. With this patch, we display a text, the count displays correctly, but when clicking on the link, we find 'all', as the empty search with ln: doesn't work right.

There are a lot of reasons why a library might not have added language information, like dealing with old/migrated data. 

For the moment I prefer Nick's solution on bug 29561 that removes those empty facets from display - so they won't appear at all if empty.

If I misunderstood something, please let me know!
Comment 3 Nick Clemens (kidclamp) 2022-10-12 13:13:25 UTC
Bug 29561 has been pushed and obsoletes this need, closing as duplicate

*** This bug has been marked as a duplicate of bug 29561 ***