Bugzilla – Attachment 148326 Details for
Bug 32301
Show correct defaultSortField in staff interface advanced search
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 32301: [alternate] Fix default search sorting in advanced search when not editing a search
Bug-32301-alternate-Fix-default-search-sorting-in-.patch (text/plain), 1.92 KB, created by
Nick Clemens (kidclamp)
on 2023-03-17 11:23:30 UTC
(
hide
)
Description:
Bug 32301: [alternate] Fix default search sorting in advanced search when not editing a search
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2023-03-17 11:23:30 UTC
Size:
1.92 KB
patch
obsolete
>From 75c9723363650b2f4ca83f752c25593955d7d2ae Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 17 Mar 2023 11:20:31 +0000 >Subject: [PATCH] Bug 32301: [alternate] Fix default search sorting in advanced > search when not editing a search > >Bug 22605 changed the sorting to expect the passed parameter from the >previous search, this broke default when the search page was loaded >fresh. > >We should simply fallback from the edited search to the default if it is >not set > >To test: >1) Go to staff client >2) Go to Advanced Search >3) Notice the default Sort By value is "Relevance" >4) Go to system preferences >5) Go to "defaultSortField" >6) Change the value of the system preference >7) Go back to Advanced Search and refresh the page >8) Notice that there are no changes, the default Sort By is still >"Relevance" >9) Apply patch >10) Notice that changing the system preference now changes the default >Sort By in Advanced Search >11) Perform a search, change the sorting, then edit the search >12) Confirm the correct sorting from the search is preserved >--- > koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt >index f966029aa6..87ab983b0e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt >@@ -389,7 +389,7 @@ > <p> > <label for="sort_by">Sort by: </label> > <select id="sort_by" name="sort_by"> >- [% INCLUDE 'resort_form.inc' sort_by = sort %] >+ [% INCLUDE 'resort_form.inc' sort_by = sort || sort_by %] > </select> > </p> > </fieldset> <!-- /#sortby --> >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 32301
:
144096
|
144310
|
144327
|
147984
|
148326
|
148973
|
149405