Bugzilla – Attachment 124804 Details for
Bug 28831
OPAC XSLT Results: Allow unavailable item grouping on status only for large consortia
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28831: Database revision, add new preference
Bug-28831-Database-revision-add-new-preference.patch (text/plain), 4.63 KB, created by
David Nind
on 2021-09-12 05:36:03 UTC
(
hide
)
Description:
Bug 28831: Database revision, add new preference
Filename:
MIME Type:
Creator:
David Nind
Created:
2021-09-12 05:36:03 UTC
Size:
4.63 KB
patch
obsolete
>From 02b33a2e4e8d006693b7dd0c9ba1e6dd26e42401 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 9 Sep 2021 09:37:50 +0000 >Subject: [PATCH] Bug 28831: Database revision, add new preference > >The preference OPACResultsUnavailableGroupingBy allows you to >group unavailable items by substatus, only showing item counts, on >the OPAC XSLT results. > >This is meant to be useful for larger consortia. > >Test plan: >Run dbrev. >Check new pref on Admin, preferences, OPAC tab. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> > >Signed-off-by: David Nind <david@davidnind.com> >--- > installer/data/mysql/atomicupdate/bug_28831.pl | 14 ++++++++++++++ > installer/data/mysql/mandatory/sysprefs.sql | 1 + > .../prog/en/modules/admin/preferences/opac.pref | 8 +++++++- > 3 files changed, 22 insertions(+), 1 deletion(-) > create mode 100755 installer/data/mysql/atomicupdate/bug_28831.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_28831.pl b/installer/data/mysql/atomicupdate/bug_28831.pl >new file mode 100755 >index 0000000000..edcda610b5 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_28831.pl >@@ -0,0 +1,14 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => "28831", >+ description => "Add system preferences OPACResultsUnavailableGroupingBy", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ $dbh->do(q| >+ INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) VALUES >+ ('OPACResultsUnavailableGroupingBy','branch','branch\|substatus','Group OPAC XSLT results by branch or substatus','Choice') >+ |); >+ }, >+} >diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql >index 59db857ca6..8c2ffd1a8e 100644 >--- a/installer/data/mysql/mandatory/sysprefs.sql >+++ b/installer/data/mysql/mandatory/sysprefs.sql >@@ -458,6 +458,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('OpacResetPassword','0','','Shows the ''Forgot your password?'' link in the OPAC','YesNo'), > ('OPACResultsLibrary', 'homebranch', 'homebranch|holdingbranch', 'Defines whether the OPAC displays the holding or home branch in search results when using XSLT', 'Choice'), > ('OPACResultsSidebar','','70|10','Define HTML to be included on the search results page, underneath the facets sidebar','Textarea'), >+('OPACResultsUnavailableGroupingBy','branch','branch|substatus','Group OPAC XSLT results by branch or substatus','Choice'), > ('OPACSearchForTitleIn','<a href=\"https://worldcat.org/search?q={TITLE}\" target=\"_blank\">Other Libraries (WorldCat)</a>\n<a href=\"https://scholar.google.com/scholar?q={TITLE}\" target=\"_blank\">Other Databases (Google Scholar)</a>\n<a href=\"https://www.bookfinder.com/search/?author={AUTHOR}&title={TITLE}&st=xl&ac=qr\" target=\"_blank\">Online Stores (Bookfinder.com)</a>\n<a href=\"https://openlibrary.org/search?author=({AUTHOR})&title=({TITLE})\" target=\"_blank\">Open Library (openlibrary.org)</a>','70|10','Enter the HTML that will appear in the \'Search for this title in\' box on the detail page in the OPAC. Enter {TITLE}, {AUTHOR}, or {ISBN} in place of their respective variables in the URL. Leave blank to disable \'More Searches\' menu.','Textarea'), > ('OpacSeparateHoldings','0',NULL,'Separate current branch holdings from other holdings (OPAC)','YesNo'), > ('OpacSeparateHoldingsBranch','homebranch','homebranch|holdingbranch','Branch used to separate holdings (OPAC)','Choice'), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >index 179e16b529..c3e793794c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >@@ -348,7 +348,13 @@ OPAC: > - pref: OPACResultsMaxItems > - (available) individual items on the OPAC XSLT search results, and show no more than > - pref: OPACResultsMaxItemsUnavailable >- - "'really unavailable' individual items in categories like Checked out, Damaged, On Hold, etc." >+ - "(unavailable) individual items for categories like Checked out, Damaged, On Hold, but only when you group them by branch.<br>" >+ - Group unavailable items by >+ - pref: OPACResultsUnavailableGroupingBy >+ choices: >+ branch: "branch" >+ substatus: "substatus" >+ - ". (NOTE: For large consortia we recommend to group unavailable items by substatus, listing item counts only.)" > > Features: > - >-- >2.20.1
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 28831
:
124688
|
124689
|
124690
|
124706
|
124707
|
124708
|
124804
|
124805
|
124806
|
125894
|
125895
|
125896
|
126031
|
126032
|
126033