elsif ( @$tags[$i] eq "thesaurus" ) {
$attr = " \@attr 1=Subject-heading-thesaurus ";
}
- else { # Assume any if no index was specified
+ elsif ( @$tags[$i] eq "all" ) {
$attr = " \@attr 1=Any ";
}
+ else { # Use the index passed in params
+ $attr = " \@attr 1=" . @$tags[$i] . " ";
+ }
} #if @$tags[$i]
else { # Assume any if no index was specified
$attr = " \@attr 1=Any ";
if ($QParser) {
$op = '&&';
} else {
- $op = 'and';
+ $op = 'AND';
}
my $query='at:'.$authtypecode.' ';
my $filtervalues=qr([\001-\040\Q!'"`#$%&*+,-./:;<=>?@(){[}_|~\E\]]);
my $newtag = $tags_new && @$tags_new
? _merge_newtag( $tag, $tags_new )
: $tag;
- my $controlled_ind = Koha::Authority->new({ authtypecode => $authtypeto ? $authtypeto->authtypecode : undef })->controlled_indicators({ record => $MARCto, biblio_tag => $newtag }); #FIXME Replace this tric with new when refactoring
+ my $controlled_ind = $authto->controlled_indicators({ record => $MARCto, biblio_tag => $newtag });
my $field_to = MARC::Field->new(
$newtag,
$controlled_ind->{ind1} // $field->indicator(1),