@@ -, +, @@ --- C4/XSLT.pm | 2 +- installer/data/mysql/sysprefs.sql | 1 + installer/data/mysql/updatedatabase.pl | 7 ++ .../prog/en/modules/admin/preferences/opac.pref | 7 ++ .../prog/en/xslt/MARC21slim2OPACResults.xsl | 72 ++++++++++++++------ 5 files changed, 67 insertions(+), 22 deletions(-) --- a/C4/XSLT.pm +++ a/C4/XSLT.pm @@ -188,7 +188,7 @@ sub XSLTParse4Display { UseAuthoritiesForTracings TraceSubjectSubdivisions Display856uAsImage OPACDisplay856uAsImage UseControlNumber IntranetBiblioDefaultView BiblioDefaultView - singleBranchMode + singleBranchMode OPACResultsBranchXSLT AlternateHoldingsField AlternateHoldingsSeparator / ) { my $sp = C4::Context->preference( $syspref ); --- a/installer/data/mysql/sysprefs.sql +++ a/installer/data/mysql/sysprefs.sql @@ -383,3 +383,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES(' INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowLibrariesPulldownMobile','1','Show the libraries pulldown on the mobile version of the OPAC.',NULL,'YesNo'); INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowFiltersPulldownMobile','1','Show the search filters pulldown on the mobile version of the OPAC.',NULL,'YesNo'); INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES('AuthDisplayHierarchy','0','Display authority hierarchies','','YesNo'); +INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('OPACResultsBranchXSLT', 'homebranch', 'homebranch|holdingbranch', 'Defines whether the OPAC displays the holding or home branch in search results when using XSLT', 'Choice'); --- a/installer/data/mysql/updatedatabase.pl +++ a/installer/data/mysql/updatedatabase.pl @@ -5982,6 +5982,13 @@ if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { SetVersion($DBversion); } +$DBversion = "3.09.00.XXX"; +if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { + $dbh->do("INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('OPACResultsBranchXSLT', 'homebranch', 'homebranch|holdingbranch', 'Defines whether the OPAC displays the holding or home branch in search results when using XSLT', 'Choice')"); + print "Upgrade to $DBversion done (Adds permissions flag for access to the patron modifications tool)\n"; + SetVersion($DBversion); +} + =head1 FUNCTIONS =head2 TableExists($table) --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref @@ -73,6 +73,13 @@ OPAC: no: "don't show" - icons for itemtype and authorized values. - + - On search result pages displayed with XSLT stylesheets on the OPAC, show the item's + - pref: OPACResultsBranchXSLT + choices: + holdingbranch: "holding branch" + homebranch: "home branch" + - icons for itemtype and authorized values. + - - pref: COinSinOPACResults choices: yes: Include --- a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACResults.xsl +++ a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACResults.xsl @@ -9,7 +9,8 @@ - + + @@ -19,6 +20,7 @@ + @@ -1028,23 +1030,37 @@ select="key('item-by-status', 'available')"/> - + [] ( - + ) . , - - - [] - ( - - ) - . , - + + + + + [] + ( + + ) + . , + + + + + + [] + ( + + ) + . , + + + @@ -1062,16 +1078,30 @@ Copies available for reference: - - - - [] - ( - - ) - . , - + + + + + + + [] + ( + + ) + . , + + + + + + [] + ( + + ) + . , + + + --