]> git.koha-community.org Git - koha.git/commit
Bug 27697: Only preopulate search when we have found a single biblio
authorNick Clemens <nick@bywatersolutions.com>
Wed, 18 May 2022 15:08:39 +0000 (15:08 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Thu, 2 Jun 2022 16:40:15 +0000 (13:40 -0300)
commit022330b8d26b81e53f9c4af7798fa42ff48bdaa3
treed831ca318cebc75ab6025812bf2c623bea640d8d
parent34b84b68e509c9172b850dad4dbc5b7e9f518225
Bug 27697: Only preopulate search when we have found a single biblio

This patch uses the url parameter we created in 23475 to determine whether
we should populate the search bar or not

Note - a bookmark with this param will still populate search term with last search

To test:
1 - Search staff client for 'cat'
2 - Browse to a patrons checkouts and click on a title, or just go directly to a details page:
    http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=2850
3 - Search bar says 'cat'
4 - Apply patch
5 - Repeat 1-2
6 - Search bar is not populated
7 - Search "dalek war box set" or a term that finds a single record in your instance
8 - Search bar is populated
9 - Note url like: http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=2850&found1=1

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
catalogue/detail.pl
koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt