From f588516902b1202b9e46e8c5f543446db3c45dfc Mon Sep 17 00:00:00 2001 From: Nahuel ANGELINETTI Date: Wed, 15 Jul 2009 11:01:27 +0200 Subject: [PATCH] (bug #3398) fix unimarc 210c plugin this add some args to SearchAuthority(); Fix the pagination, and fix javascript script. Signed-off-by: Galen Charlton Signed-off-by: Henri-Damien LAURENT --- .../value_builder/unimarc_field_210c.pl | 9 +++---- .../value_builder/unimarc_field_210c.tmpl | 24 +++++++++++++++---- 2 files changed, 24 insertions(+), 9 deletions(-) diff --git a/cataloguing/value_builder/unimarc_field_210c.pl b/cataloguing/value_builder/unimarc_field_210c.pl index 27ced1948c..ffbf644557 100755 --- a/cataloguing/value_builder/unimarc_field_210c.pl +++ b/cataloguing/value_builder/unimarc_field_210c.pl @@ -162,7 +162,8 @@ my ($input) = @_; my @excluding = $query->param('excluding'); my @operator = $query->param('operator'); my @value = $query->param('value'); - + my $orderby = $query->param('orderby'); + $resultsperpage= $query->param('resultsperpage'); $resultsperpage = 19 if(!defined $resultsperpage); @@ -171,8 +172,8 @@ my ($input) = @_; my ($results,$total) = SearchAuthorities( \@tags,\@and_or, \@excluding, \@operator, \@value, - $startfrom*$resultsperpage, $resultsperpage,$authtypecode);# $orderby); - + $startfrom*$resultsperpage, $resultsperpage,$authtypecode, $orderby); + ($template, $loggedinuser, $cookie) = get_template_and_user({template_name => "cataloguing/value_builder/unimarc_field_210c.tmpl", query => $query, @@ -211,7 +212,7 @@ my ($input) = @_; } else { $to = (($startfrom+1)*$resultsperpage); } - my $link="../cataloguing/plugin_launcher.pl?plugin_name=unimarc_field_210c.pl&authtypecode=EDITORS&and_or=and&operator=contains&".join("&",map {"value=".$_} @value)."&op=do_search&type=intranet&index=$index"; + my $link="../cataloguing/plugin_launcher.pl?plugin_name=unimarc_field_210c.pl&authtypecode=EDITORS&and_or=$and_or&marclist=$marclist&operator=$operator&orderby=$orderby&excluding=$excluding&".join("&",map {"value=".$_} @value)."&op=do_search&type=intranet&index=$index"; warn "$link ,".getnbpages($total, $resultsperpage); $template->param(result => $results) if $results; $template->param('index' => $query->param('index')); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tmpl index 4948ca35e0..8da1f39c92 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tmpl @@ -21,6 +21,20 @@ "> "> + + + + + +

@@ -53,7 +67,7 @@ times - ','')">choose//images/arrow.gif" width="32" hspace="0" vspace="0" border="0"> + ')">choose//images/arrow.gif" width="32" hspace="0" vspace="0" border="0"> @@ -70,14 +84,14 @@ -- 2.39.5