From 7d4a962a18ffe1118334b0fd1e83aa91e6075cea Mon Sep 17 00:00:00 2001 From: Garry Collum Date: Thu, 11 Jun 2009 16:44:30 -0400 Subject: [PATCH] Bug 2889: Removed toggle from marc_subfields_structure.pl and .tmpl Removed toggle variable from marc_subfields_structure.pl and marc_subfields_structure.tmpl. Used template __odd__ variable instead. Corrected a typo in the highlight class definition in .tmpl. Corrected a readability issue with the description when deleting a subfield in .tmpl. Signed-off-by: Galen Charlton --- admin/marc_subfields_structure.pl | 17 ----------------- .../modules/admin/marc_subfields_structure.tmpl | 8 ++++++-- 2 files changed, 6 insertions(+), 19 deletions(-) diff --git a/admin/marc_subfields_structure.pl b/admin/marc_subfields_structure.pl index a4c0697ada..7bcd0dc4bf 100755 --- a/admin/marc_subfields_structure.pl +++ b/admin/marc_subfields_structure.pl @@ -174,16 +174,9 @@ if ( $op eq 'add_form' ) { ); # and tagsubfield='$tagsubfield'"); $sth->execute( $tagfield, $frameworkcode ); my @loop_data = (); - my $toggle = 1; my $i = 0; while ( $data = $sth->fetchrow_hashref ) { my %row_data; # get a fresh hash for the row data - if ( $toggle eq 1 ) { - $toggle = 0; - } - else { - $toggle = 1; - } $row_data{defaultvalue} = $data->{defaultvalue}; $row_data{tab} = CGI::scrolling_list( -name => 'tab', @@ -273,7 +266,6 @@ if ( $op eq 'add_form' ) { -label => '' ); $row_data{row} = $i; - $row_data{toggle} = $toggle; $row_data{link} = CGI::escapeHTML( $data->{'link'} ); push( @loop_data, \%row_data ); $i++; @@ -368,7 +360,6 @@ if ( $op eq 'add_form' ) { -multiple => 0, ); $row_data{link} = CGI::escapeHTML( $data->{'link'} ); - $row_data{toggle} = $toggle; $row_data{row} = $j; push( @loop_data, \%row_data ); } @@ -538,7 +529,6 @@ elsif ( $op eq 'delete_confirmed' ) { } else { # DEFAULT my ( $count, $results ) = string_search( $tagfield, $frameworkcode ); - my $toggle = 1; my @loop_data = (); for ( my $i = $offset ; @@ -546,12 +536,6 @@ else { # DEFAULT $i++ ) { - if ( $toggle eq 1 ) { - $toggle = 0; - } - else { - $toggle = 1; - } my %row_data; # get a fresh hash for the row data $row_data{tagfield} = $results->[$i]{'tagfield'}; $row_data{tagsubfield} = $results->[$i]{'tagsubfield'}; @@ -571,7 +555,6 @@ else { # DEFAULT "$script_name?op=delete_confirm&tagfield=$tagfield&tagsubfield=" . $results->[$i]{'tagsubfield'} . "&frameworkcode=$frameworkcode"; - $row_data{toggle} = $toggle; if ( $row_data{tab} eq -1 ) { $row_data{subfield_ignored} = 1; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tmpl index 55b3a4b377..2ea58de440 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tmpl @@ -135,7 +135,7 @@

Confirm Deletion of Subfield ?

Subfield:

-

Description

+

Description:

" method="post"> " /> @@ -177,7 +177,11 @@ Delete - + + + + + -- 2.39.5