[Koha-cvs] CVS: koha loadmodules.pl,1.12,1.13

Paul POULAIN tipaul at users.sourceforge.net
Tue Mar 4 17:16:22 CET 2003


Update of /cvsroot/koha/koha
In directory sc8-pr-cvs1:/tmp/cvs-serv12073

Modified Files:
	loadmodules.pl 
Log Message:
MARC search fixes and improvements. Now, ALL searches are indexed and should be very fast with any statement.
a few improvments, and it will be useable even with a NON-MARC installation of koha.

Index: loadmodules.pl
===================================================================
RCS file: /cvsroot/koha/koha/loadmodules.pl,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** loadmodules.pl	13 Feb 2003 18:02:10 -0000	1.12
--- loadmodules.pl	4 Mar 2003 16:16:18 -0000	1.13
***************
*** 36,40 ****
  }
  
- 
  sub acquisitions {
  	my $aq_type = C4::Context->preference("acquisitions") || "normal";
--- 36,39 ----
***************
*** 56,65 ****
  	my $marc_p = C4::Context->boolean_preference("marc");
  	$marc_p = 1 unless defined $marc_p;
  	my $query = new CGI;
  	my $type = $query->param('type');
! 	if ($marc_p) {
! 		print $input->redirect("/cgi-bin/koha/search.marc/search.pl?type=$type");
  	} else {
! 		print $input ->redirect("/cgi-bin/koha/catalogue-home.pl");
  	}
  }
--- 55,73 ----
  	my $marc_p = C4::Context->boolean_preference("marc");
  	$marc_p = 1 unless defined $marc_p;
+ 	my $keyword=$input->param('keyword');
  	my $query = new CGI;
  	my $type = $query->param('type');
! 	if ($keyword) {
! 		if ($marc_p) {
! 			print $input->redirect("/cgi-bin/koha/search.marc/search.pl?type=$type");
! 		} else {
! 			print $input ->redirect("/cgi-bin/koha/search.pl?keyword=$keyword");
! 		}
  	} else {
! 		if ($marc_p) {
! 			print $input->redirect("/cgi-bin/koha/search.marc/search.pl?type=$type");
! 		} else {
! 			print $input ->redirect("/cgi-bin/koha/catalogue-home.pl");
! 		}
  	}
  }





More information about the Koha-cvs mailing list