update for missing subscriptions.lastbranch col in serials
[koha_fer] / admin / authtypes.pl
index 0195190..baeb27c 100755 (executable)
 use strict;
 use CGI;
 use C4::Context;
-use C4::Output;
-use C4::Search;
 use C4::Auth;
-use C4::Interface::CGI::Output;
-use HTML::Template;
+use C4::Output;
+
 
 sub StringSearch  {
-       my ($env,$searchstring,$type)=@_;
+       my ($searchstring,$type)=@_;
        my $dbh = C4::Context->dbh;
        $searchstring=~ s/\'/\\\'/g;
        my @data=split(' ',$searchstring);
@@ -56,7 +54,7 @@ my $pagesize=20;
 my $op = $input->param('op');
 $searchfield=~ s/\,//g;
 my ($template, $borrowernumber, $cookie)
-    = get_template_and_user({template_name => "parameters/authtypes.tmpl",
+    = get_template_and_user({template_name => "admin/authtypes.tmpl",
                             query => $input,
                             type => "intranet",
                             authnotrequired => 0,
@@ -69,7 +67,7 @@ $template->param(script_name => $script_name,
                                                $op              => 1); # we show only the TMPL_VAR names $op
 } else {
 $template->param(script_name => $script_name,
-                                               else              => 1); # we show only the TMPL_VAR names $op
+                                               'else'              => 1); # we show only the TMPL_VAR names $op
 }
 ################## ADD_FORM ##################################
 # called by default. Used to create form to add or  modify a record
@@ -144,8 +142,7 @@ if ($op eq 'add_form') {
                                                                                                        # END $OP eq DELETE_CONFIRMED
 ################## DEFAULT ##################################
 } else { # DEFAULT
-       my $env;
-       my ($count,$results)=StringSearch($env,$searchfield,'web');
+       my ($count,$results)=StringSearch($searchfield,'web');
        my $toggle="white";
        my @loop_data;
        for (my $i=$offset; $i < ($offset+$pagesize<$count?$offset+$pagesize:$count); $i++){