39 |
my @excluding = $query->param('excluding'); |
my @excluding = $query->param('excluding'); |
40 |
my @operator = $query->param('operator'); |
my @operator = $query->param('operator'); |
41 |
my @value = $query->param('value'); |
my @value = $query->param('value'); |
42 |
|
my $orderby = $query->param('orderby'); |
43 |
|
my $desc_or_asc = $query->param('desc_or_asc'); |
44 |
|
my $exactsearch = $query->param('exact'); |
45 |
|
|
46 |
for (my $i=0;$i<=$#marclist;$i++) { |
for (my $i=0;$i<=$#marclist;$i++) { |
47 |
if ($searchdesc) { # don't put the and_or on the 1st search term |
if ($searchdesc) { # don't put the and_or on the 1st search term |
48 |
$searchdesc .= $and_or[$i]." ".$excluding[$i]." ".($marclist[$i]?$marclist[$i]:"*")." ".$operator[$i]." ".$value[$i]." " if ($value[$i]); |
$searchdesc .= $and_or[$i].$excluding[$i]." ".($marclist[$i]?$marclist[$i]:"*").$operator[$i].$value[$i] if ($value[$i]); |
49 |
} else { |
} else { |
50 |
$searchdesc = $excluding[$i]." ".($marclist[$i]?$marclist[$i]:"*")." ".$operator[$i]." ".$value[$i]." " if ($value[$i]); |
$searchdesc = $excluding[$i].($marclist[$i]?$marclist[$i]:"*").$operator[$i].$value[$i] if ($value[$i]); |
51 |
} |
} |
52 |
} |
} |
53 |
$resultsperpage= $query->param('resultsperpage'); |
$resultsperpage= $query->param('resultsperpage'); |
54 |
$resultsperpage = 19 if(!defined $resultsperpage); |
$resultsperpage = 19 if(!defined $resultsperpage); |
55 |
|
|
|
my $orderby = $query->param('orderby'); |
|
|
my $desc_or_asc = $query->param('desc_or_asc'); |
|
|
my $exactsearch = $query->param('exact'); |
|
56 |
if ($exactsearch) { |
if ($exactsearch) { |
|
warn "EXACT"; |
|
57 |
foreach (@operator) { |
foreach (@operator) { |
58 |
$_='='; |
$_='='; |
59 |
} |
} |
113 |
push @field_data, { term => "operator", val=>$operator[$i] }; |
push @field_data, { term => "operator", val=>$operator[$i] }; |
114 |
push @field_data, { term => "value", val=>$value[$i] }; |
push @field_data, { term => "value", val=>$value[$i] }; |
115 |
} |
} |
116 |
|
push @field_data, {term => "desc_or_asc", val => $desc_or_asc} if $desc_or_asc; |
117 |
|
push @field_data, {term => "orderby", val => $orderby} if $orderby; |
118 |
my @numbers = (); |
my @numbers = (); |
119 |
|
|
120 |
if ($total>$resultsperpage) |
if ($total>$resultsperpage) |