Bug 33217 - Allow different default sorting when click author links
Summary: Allow different default sorting when click author links
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Searching (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Nick Clemens (kidclamp)
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-13 19:34 UTC by Nick Clemens (kidclamp)
Modified: 2024-01-09 15:21 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact: Rasa Satinskiene
Documentation submission: https://gitlab.com/koha-community/koha-manual/-/merge_requests/807
Text to go in the release notes:
Authors and contributors in the detail pages are linked to search for more materials of the same persons or institutions. Before this patch, these would use the normal default sorting, like relevancy, which isn't as helpful for these results. The new system preferences `AuthorLinkSortBy` and `AuthorLinkSortOrder` now allow to change the sort order for these links specifically.
Version(s) released in:
23.11.00
Circulation function:


Attachments
Bug 33217: Allow specifiying sort field and order for authro links (21.38 KB, patch)
2023-03-13 19:50 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 33217: DB update (1.37 KB, patch)
2023-03-14 15:13 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 33217: Allow specifiying sort field and order for authro links (21.44 KB, patch)
2023-10-25 12:34 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 33217: DB update (1.41 KB, patch)
2023-10-25 12:34 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 33217: Tidy (2.69 KB, patch)
2023-10-25 12:34 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 33217: Allow specifiying sort field and order for authro links (21.50 KB, patch)
2023-10-25 15:30 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 33217: DB update (1.47 KB, patch)
2023-10-25 15:30 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 33217: Tidy (2.74 KB, patch)
2023-10-25 15:30 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 33217: Allow specifiying sort field and order for authro links (21.56 KB, patch)
2023-11-05 01:50 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 33217: DB update (1.52 KB, patch)
2023-11-05 01:50 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 33217: Tidy (2.80 KB, patch)
2023-11-05 01:50 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 33217: (QA follow-up) Tiny tidy of atomicupdate (1.32 KB, patch)
2023-11-05 01:50 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 33217: (QA follow-up) Improve system preference description (2.20 KB, patch)
2023-11-05 01:50 UTC, Katrin Fischer
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) 2023-03-13 19:34:07 UTC
When using the facets for author, i.e. limiting a search, it makes sense to preserve the default sort order for the results (relevance, etc)

When clicking on an author to search the catalog for all works by an author, it would be nice to be able to optionally specify sorting for the listing - i.e. publication date, or title
Comment 1 Nick Clemens (kidclamp) 2023-03-13 19:50:36 UTC
Created attachment 148142 [details] [review]
Bug 33217: Allow specifiying sort field and order for authro links

When using the facets for author, i.e. limiting a search, it makes sense to preserve the default sort order for the results (relevance, etc)

When clicking on an author to search the catalog for all works by an author, it would be nice to be able to optionally specify sorting for the listing - i.e. publication date, or title

This patch adds two new system preferences:
AuthorLinkSortBy
AuthorLinkSortOrder

To test:
1 - Do a search in intranet and staff for 'austen'
    or an author you have multiple titles from
2 - Click the linked name
3 - Note a new search is performed, sorted by field from
    defaultSortField  preference
4 - Apply patch, updatedatabase, restart_all
5 - Ensure nothing has changed by searching again
6 - Set AuthorLinkSortBy to 'date of publication' and
    AuthorLinkSortORder to asc
7 - Search again, comfirm links obey sorting specific above
8 - Test other values - confirm links are updated in both staff/opac
    and results/details
Comment 2 Nick Clemens (kidclamp) 2023-03-14 15:13:04 UTC
Created attachment 148169 [details] [review]
Bug 33217: DB update
Comment 3 Nick Clemens (kidclamp) 2023-05-17 19:48:05 UTC
Sorting dropdown does not show correct value after applying
Comment 4 Nick Clemens (kidclamp) 2023-10-25 12:34:05 UTC
Created attachment 157795 [details] [review]
Bug 33217: Allow specifiying sort field and order for authro links

When using the facets for author, i.e. limiting a search, it makes sense to preserve the default sort order for the results (relevance, etc)

When clicking on an author to search the catalog for all works by an author, it would be nice to be able to optionally specify sorting for the listing - i.e. publication date, or title

This patch adds two new system preferences:
AuthorLinkSortBy
AuthorLinkSortOrder

To test:
1 - Do a search in intranet and staff for 'austen'
    or an author you have multiple titles from
2 - Click the linked name
3 - Note a new search is performed, sorted by field from
    defaultSortField  preference
4 - Apply patch, updatedatabase, restart_all
5 - Ensure nothing has changed by searching again
6 - Set AuthorLinkSortBy to 'date of publication' and
    AuthorLinkSortORder to asc
7 - Search again, comfirm links obey sorting specific above
8 - Test other values - confirm links are updated in both staff/opac
    and results/details
Comment 5 Nick Clemens (kidclamp) 2023-10-25 12:34:07 UTC
Created attachment 157796 [details] [review]
Bug 33217: DB update
Comment 6 Nick Clemens (kidclamp) 2023-10-25 12:34:09 UTC
Created attachment 157797 [details] [review]
Bug 33217: Tidy
Comment 7 ByWater Sandboxes 2023-10-25 15:30:36 UTC
Created attachment 157818 [details] [review]
Bug 33217: Allow specifiying sort field and order for authro links

When using the facets for author, i.e. limiting a search, it makes sense to preserve the default sort order for the results (relevance, etc)

When clicking on an author to search the catalog for all works by an author, it would be nice to be able to optionally specify sorting for the listing - i.e. publication date, or title

This patch adds two new system preferences:
AuthorLinkSortBy
AuthorLinkSortOrder

To test:
1 - Do a search in intranet and staff for 'austen'
    or an author you have multiple titles from
2 - Click the linked name
3 - Note a new search is performed, sorted by field from
    defaultSortField  preference
4 - Apply patch, updatedatabase, restart_all
5 - Ensure nothing has changed by searching again
6 - Set AuthorLinkSortBy to 'date of publication' and
    AuthorLinkSortORder to asc
7 - Search again, comfirm links obey sorting specific above
8 - Test other values - confirm links are updated in both staff/opac
    and results/details

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Comment 8 ByWater Sandboxes 2023-10-25 15:30:38 UTC
Created attachment 157819 [details] [review]
Bug 33217: DB update

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Comment 9 ByWater Sandboxes 2023-10-25 15:30:40 UTC
Created attachment 157820 [details] [review]
Bug 33217: Tidy

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Comment 10 Katrin Fischer 2023-11-05 01:50:33 UTC
Created attachment 158434 [details] [review]
Bug 33217: Allow specifiying sort field and order for authro links

When using the facets for author, i.e. limiting a search, it makes sense to preserve the default sort order for the results (relevance, etc)

When clicking on an author to search the catalog for all works by an author, it would be nice to be able to optionally specify sorting for the listing - i.e. publication date, or title

This patch adds two new system preferences:
AuthorLinkSortBy
AuthorLinkSortOrder

To test:
1 - Do a search in intranet and staff for 'austen'
    or an author you have multiple titles from
2 - Click the linked name
3 - Note a new search is performed, sorted by field from
    defaultSortField  preference
4 - Apply patch, updatedatabase, restart_all
5 - Ensure nothing has changed by searching again
6 - Set AuthorLinkSortBy to 'date of publication' and
    AuthorLinkSortORder to asc
7 - Search again, comfirm links obey sorting specific above
8 - Test other values - confirm links are updated in both staff/opac
    and results/details

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 11 Katrin Fischer 2023-11-05 01:50:36 UTC
Created attachment 158435 [details] [review]
Bug 33217: DB update

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 12 Katrin Fischer 2023-11-05 01:50:38 UTC
Created attachment 158436 [details] [review]
Bug 33217: Tidy

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 13 Katrin Fischer 2023-11-05 01:50:41 UTC
Created attachment 158437 [details] [review]
Bug 33217: (QA follow-up) Tiny tidy of atomicupdate

Just adds an end and removes the commented line.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 14 Katrin Fischer 2023-11-05 01:50:44 UTC
Created attachment 158438 [details] [review]
Bug 33217: (QA follow-up) Improve system preference description

* Make sure MARC21 is mentioned, as this only updates MARC21 XSLT files
* Move ending punctuation outside the pull down
* remove 'obey' - it's not needed

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 15 Tomás Cohen Arazi (tcohen) 2023-11-08 20:55:23 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 16 Fridolin Somers 2023-11-11 01:42:41 UTC
Enhancement not pushed to 23.05.x
Comment 17 Rasa Satinskiene 2024-01-09 15:21:47 UTC
Manual updated