@@ -, +, @@ --- installer/data/mysql/atomicupdate/bug-22581.perl | 12 ++++++++++++ installer/data/mysql/sysprefs.sql | 2 ++ .../prog/en/modules/admin/preferences/opac.pref | 14 ++++++++++++++ 3 files changed, 28 insertions(+) create mode 100644 installer/data/mysql/atomicupdate/bug-22581.perl --- a/installer/data/mysql/atomicupdate/bug-22581.perl +++ a/installer/data/mysql/atomicupdate/bug-22581.perl @@ -0,0 +1,12 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + # you can use $dbh here like: + $dbh->do( qq{ + INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) + VALUES ('OPACShowMusicalInscripts','0','','Display musical inscripts on the OPAC record details page when available.','YesNo'), + ('OPACPlayMusicalInscripts','0','','If displayed musical inscripts, play midi conversion on the OPAC record details page.','YesNo') + } ); + + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 22581 - add new OPACShowMusicalInscripts and OPACPlayMusicalInscripts system preferences)\n"; +} --- a/installer/data/mysql/sysprefs.sql +++ a/installer/data/mysql/sysprefs.sql @@ -428,6 +428,8 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('OPACShelfBrowser','1','','Enable/disable Shelf Browser on item details page. WARNING: this feature is very resource consuming on collections with large numbers of items.','YesNo'), ('OPACShowCheckoutName','0','','Displays in the OPAC the name of patron who has checked out the material. WARNING: Most sites should leave this off. It is intended for corporate or special sites which need to track who has the item.','YesNo'), ('OPACShowHoldQueueDetails','none','none|priority|holds|holds_priority','Show holds details in OPAC','Choice'), +('OPACShowMusicalInscripts','0','','Display musical inscripts on the OPAC record details page when available.','YesNo'), +('OPACPlayMusicalInscripts','0','','If displayed musical inscripts, play midi conversion on the OPAC record details page.','YesNo'), ('OpacShowRecentComments','0',NULL,'If ON a link to recent comments will appear in the OPAC masthead','YesNo'), ('OPACShowUnusedAuthorities','1','','Show authorities that are not being used in the OPAC.','YesNo'), ('OpacStarRatings','all','disable|all|details',NULL,'Choice'), --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref @@ -162,6 +162,20 @@ OPAC: - "for items on the OPAC record details page." - "
Note: If 'on a separate column' is selected, you still need to enable the item_shelving_location display on the configure columns administration page" - + - pref: OPACShowMusicalInscripts + default: 0 + choices: + yes: Show + no: "Don't show" + - musical inscripts on the OPAC record details page. + - + - pref: OPACPlayMusicalInscripts + default: 0,'','If displayed musical inscripts, play midi conversion for items on the OPAC record details page.' + choices: + yes: Play + no: "Don't play" + - MIDI representation of musical inscripts on the OPAC record details page. + - - pref: OpacKohaUrl default: 0 choices: --