From cc6641221e892a4feaf67c0cd9f0c39821273d61 Mon Sep 17 00:00:00 2001 From: Jane Wagner Date: Wed, 16 Jun 2010 14:29:04 -0400 Subject: [PATCH] Bug 3634 Add support for link resolver such as SFX Creates two sysprefs to enable link resolver and enter a URL for the link resolver server. Link will appear in righthand box on the details page, along with Place Hold, Print, etc. --- admin/systempreferences.pl | 2 ++ installer/data/mysql/de-DE/mandatory/sysprefs.sql | 3 +++ installer/data/mysql/en/mandatory/sysprefs.sql | 3 +++ .../1-Obligatoire/unimarc_standard_systemprefs.sql | 2 ++ installer/data/mysql/pl-PL/mandatory/sysprefs.sql | 2 ++ ...m_preferences_full_optimal_for_install_only.sql | 3 +++ installer/data/mysql/updatedatabase.pl | 14 ++++++++++++++ koha-tmpl/opac-tmpl/prog/en/css/opac.css | 6 +++++- .../opac-tmpl/prog/en/modules/opac-detail.tmpl | 3 +++ opac/opac-detail.pl | 2 ++ 10 files changed, 39 insertions(+), 1 deletions(-) diff --git a/admin/systempreferences.pl b/admin/systempreferences.pl index 824b058..0a2e77d 100755 --- a/admin/systempreferences.pl +++ b/admin/systempreferences.pl @@ -288,6 +288,8 @@ $tabsysprefs{AmazonSimilarItems} = "EnhancedContent"; $tabsysprefs{OPACAmazonSimilarItems} = "EnhancedContent"; $tabsysprefs{AmazonReviews} = "EnhancedContent"; $tabsysprefs{OPACAmazonReviews} = "EnhancedContent"; +$tabsysprefs{OPAClinkresolver} = "EnhancedContent"; +$tabsysprefs{OPAClinkresolverURL} = "EnhancedContent"; # Babelthèque $tabsysprefs{Babeltheque} = "EnhancedContent"; diff --git a/installer/data/mysql/de-DE/mandatory/sysprefs.sql b/installer/data/mysql/de-DE/mandatory/sysprefs.sql index 49a02ea..4c4f95c 100644 --- a/installer/data/mysql/de-DE/mandatory/sysprefs.sql +++ b/installer/data/mysql/de-DE/mandatory/sysprefs.sql @@ -286,3 +286,6 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI:Authorized_IPs','','.','Restricts usage of ILS-DI to some IPs','Free'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('OverduesBlockCirc','noblock','When checking out an item should overdues block checkout, generate a confirmation dialogue, or allow checkout','noblock|confirmation|block','Choice'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free'); + diff --git a/installer/data/mysql/en/mandatory/sysprefs.sql b/installer/data/mysql/en/mandatory/sysprefs.sql index 8bfed37..791ebb3 100644 --- a/installer/data/mysql/en/mandatory/sysprefs.sql +++ b/installer/data/mysql/en/mandatory/sysprefs.sql @@ -286,3 +286,6 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI:Authorized_IPs','','.','Restricts usage of ILS-DI to some IPs','Free'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('OverduesBlockCirc','noblock','When checking out an item should overdues block checkout, generate a confirmation dialogue, or allow checkout','noblock|confirmation|block','Choice'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free'); + diff --git a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql index 76db9c9..e2e6a4a 100644 --- a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql +++ b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql @@ -286,3 +286,5 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` ( `variable` , `value` , `options` , `explanation` , `type` ) VALUES ( 'PrintNoticesMaxLines', '0', '', 'If greater than 0, sets the maximum number of lines an overdue notice will print. If the number of items is greater than this number, the notice will end with a warning asking the borrower to check their online account for a full list of overdue items.', 'Integer' ); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI','0','Active les services ILS-DI à l''OPAC.','','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('OverduesBlockCirc','noblock','When checking out an item should overdues block checkout, generate a confirmation dialogue, or allow checkout','noblock|confirmation|block','Choice'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free'); diff --git a/installer/data/mysql/pl-PL/mandatory/sysprefs.sql b/installer/data/mysql/pl-PL/mandatory/sysprefs.sql index 3707294..0681946 100644 --- a/installer/data/mysql/pl-PL/mandatory/sysprefs.sql +++ b/installer/data/mysql/pl-PL/mandatory/sysprefs.sql @@ -273,3 +273,5 @@ INSERT INTO systempreferences (variable,value,explanation,options,type)VALUES('S INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('EnableOpacSearchHistory', '1', 'Enable or disable opac search history','', 'YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('RoutingListAddReserves','1','If ON the patrons on routing lists are automatically added to holds on the issue.','','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('soundon','0','Enable circulation sounds during checkin and checkout in the staff interface. Not supported by all web browsers yet.','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free'); diff --git a/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql b/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql index 2edbe10..2b2b60f 100644 --- a/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql +++ b/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql @@ -292,3 +292,6 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OPACviewMARC','1','Allow display of MARC view of bibiographic records in OPAC','','YesNo'); -- from 3.00.06.005 +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free'); + diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index a0b5c4a..8a4a890 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -3700,6 +3700,20 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { print "Upgrade to $DBversion done (Add index on guarantorid)\n"; SetVersion ($DBversion); } +$DBversion = '3.01.00.146'; +if (C4::Context->preference('Version') < TransformToNum($DBversion)){ + $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolver','0','Enable use of a link resolver such as SFX for full-text access to ISSNs','','YesNo');"); + print "Upgrade to $DBversion done adding syspref OPAClinkresolver to allow use of a link resolver such as SFX"; + SetVersion ($DBversion); +} + +$DBversion = '3.01.00.138'; +if (C4::Context->preference('Version') < TransformToNum($DBversion)){ + $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPAClinkresolverURL','','Enter URL for OPAC ISSN full-text access link resolver such as SFX, plus any additional parameters (e.g., http://mysfxserver.com/sfxlcl3/?sfx.ignore_date_threshold=1&issn=)','','free');"); + print "Upgrade to $DBversion done adding syspref OPAClinkresolverURL to allow use of a link resolver such as SFX"; + SetVersion ($DBversion); +} + =item DropAllForeignKeys($table) diff --git a/koha-tmpl/opac-tmpl/prog/en/css/opac.css b/koha-tmpl/opac-tmpl/prog/en/css/opac.css index 5142dd2..a56ac5c 100644 --- a/koha-tmpl/opac-tmpl/prog/en/css/opac.css +++ b/koha-tmpl/opac-tmpl/prog/en/css/opac.css @@ -406,6 +406,10 @@ a .term { background-image:url(../../images/print.gif); } +#action a.linkresolver { + background-image:url(../../famfamfam/silk/arrow_right.png); +} + #action a#furthersearches { background : transparent url(../../images/menu-arrow.gif) no-repeat right center; border : 1px solid #F3F3F3; @@ -1957,4 +1961,4 @@ div.ft { font-size:90%; list-style:disc outside url("../../images/item-bullet.gif"); padding:0.2em 0; -} \ No newline at end of file +} diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl index b1fdf84..450e1a7 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl @@ -798,6 +798,9 @@ YAHOO.util.Event.onContentReady("furtherm", function () {
  • Print
  • + +
  • ">Check Full Text Availability
  • +
  • " onclick="Dopop('opac-addbybiblionumber.pl?biblionumber='); return false;"> diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl index 629ebd2..064f488 100755 --- a/opac/opac-detail.pl +++ b/opac/opac-detail.pl @@ -239,6 +239,8 @@ $template->param( normalized_ean => $ean, normalized_oclc => $oclc, normalized_isbn => $isbn, + OPAClinkresolver => C4::Context->preference("OPAClinkresolver"), + OPAClinkresolverURL => C4::Context->preference("OPAClinkresolverURL"), content_identifier_exists => $content_identifier_exists, ); -- 1.5.6.5