From 5d063641c60682ca55bcf210b1dcfc6add289a09 Mon Sep 17 00:00:00 2001 From: Jared Camins-Esakov Date: Tue, 28 Sep 2010 20:33:34 -0400 Subject: [PATCH] Fix Bug 5261 broken link in Local Use sysprefs Content-Type: text/plain; charset="utf-8" This patch eliminates the sysprefs-menu.inc include file and changes the systempreferences.pl and systempreferences.tmpl files to work with the prefs-menu.inc instead. This will centralize the syspref tabs and make it easier to modify tabs in the future if necessary. This commit also changes the default tab to Acquisitions, since the Local Use tab does not work with preferences.pl at present. --- admin/preferences.pl | 3 ++- admin/systempreferences.pl | 2 +- .../prog/en/includes/sysprefs-menu.inc | 20 -------------------- .../prog/en/modules/admin/systempreferences.tmpl | 2 +- 4 files changed, 4 insertions(+), 23 deletions(-) delete mode 100644 koha-tmpl/intranet-tmpl/prog/en/includes/sysprefs-menu.inc diff --git a/admin/preferences.pl b/admin/preferences.pl index b5bcde8..7fcf5fc 100755 --- a/admin/preferences.pl +++ b/admin/preferences.pl @@ -266,7 +266,8 @@ my ( $template, $borrowernumber, $cookie ) = get_template_and_user( $lang = $template->param( 'lang' ); my $op = $input->param( 'op' ) || ''; my $tab = $input->param( 'tab' ); -$tab ||= 'local-use'; +$tab ||= 'acquisitions'; # Ideally this should be "local-use" but preferences.pl + # does not presently support local use preferences my $highlighted; diff --git a/admin/systempreferences.pl b/admin/systempreferences.pl index 824b058..411f434 100755 --- a/admin/systempreferences.pl +++ b/admin/systempreferences.pl @@ -801,7 +801,7 @@ if ( $op eq 'add_form' ) { $row_data->{delete} = "$script_name?op=delete_confirm&searchfield=" . $results->[$i]{'variable'}; push( @loop_data, $row_data ); } - $tab = ( $tab ? $tab : "Local Use" ); + $tab = ( $tab ? $tab : "local-use" ); $template->param( loop => \@loop_data, $tab => 1 ); if ( $offset > 0 ) { my $prevpage = $offset - $pagesize; diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/sysprefs-menu.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/sysprefs-menu.inc deleted file mode 100644 index 3b2fea4..0000000 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/sysprefs-menu.inc +++ /dev/null @@ -1,20 +0,0 @@ - diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/systempreferences.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/systempreferences.tmpl index 8d54fe0..de9a592 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/systempreferences.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/systempreferences.tmpl @@ -347,7 +347,7 @@
- +
-- 1.7.1