View | Details | Raw Unified | Return to bug 36616
Collapse All | Expand All

(-)a/authorities/auth_finder.pl (+22 lines)
Lines 67-72 if ( $op eq "do_search" ) { Link Here
67
    my $orderby        = $query->param('orderby')        || '';
67
    my $orderby        = $query->param('orderby')        || '';
68
    my $startfrom      = $query->param('startfrom')      || 0;
68
    my $startfrom      = $query->param('startfrom')      || 0;
69
    my $resultsperpage = $query->param('resultsperpage') || 20;
69
    my $resultsperpage = $query->param('resultsperpage') || 20;
70
    my $est_headings   = $query->param('est_headings')   || undef;
71
72
    if ( $est_headings ) {
73
        my @value_established = ( 'a', 'f', '|' );
74
        foreach ( @value_established ) {
75
            push @marclist, 'Kind-of-record';
76
            push @and_or, 'or';
77
            push @excluding, '';
78
            push @operator, 'contains';
79
            push @value, $_;
80
        }
81
    }
82
83
    use Data::Dumper;
84
    warn Dumper(\@marclist);
85
    warn Dumper(\@and_or);
86
    warn Dumper(\@excluding);
87
    warn Dumper(\@operator);
88
    warn Dumper(\@value);
89
    warn Dumper($authtypecode);
90
    warn Dumper($orderby);
70
91
71
    my $builder = Koha::SearchEngine::QueryBuilder->new(
92
    my $builder = Koha::SearchEngine::QueryBuilder->new(
72
        { index => $Koha::SearchEngine::AUTHORITIES_INDEX } );
93
        { index => $Koha::SearchEngine::AUTHORITIES_INDEX } );
Lines 76-81 if ( $op eq "do_search" ) { Link Here
76
        \@marclist, \@and_or, \@excluding, \@operator,
97
        \@marclist, \@and_or, \@excluding, \@operator,
77
        \@value, $authtypecode, $orderby
98
        \@value, $authtypecode, $orderby
78
    );
99
    );
100
79
    $template->param( search_query => $search_query ) if C4::Context->preference('DumpSearchQueryTemplate');
101
    $template->param( search_query => $search_query ) if C4::Context->preference('DumpSearchQueryTemplate');
80
    my $offset = $startfrom * $resultsperpage;
102
    my $offset = $startfrom * $resultsperpage;
81
    my ( $results, $total ) =
103
    my ( $results, $total ) =
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc (-1 / +12 lines)
Lines 116-121 Link Here
116
                    <input id="value_any" style="width:400px;" type="text" name="value_any" value="[% value_any | html %]" />
116
                    <input id="value_any" style="width:400px;" type="text" name="value_any" value="[% value_any | html %]" />
117
                    <div id="yvaluecontainermarclist"></div>
117
                    <div id="yvaluecontainermarclist"></div>
118
                </li>
118
                </li>
119
                <li>
120
                    <label for="est_headings">Established headings only: </label>
121
                    <select name="est_headings" id="est_headings">
122
                        [% IF Koha.Preference('LinkEstablishedHeadings') %]
123
                        <option value="1" selected="selected">Yes</option>
124
                        <option value="">No</option>
125
                        [% ELSE %]
126
                        <option value="1">Yes</option>
127
                        <option value="" selected="selected">No</option>
128
                        [% END %]
129
                    </select>
130
                </li>
119
        <li>
131
        <li>
120
        <label for="orderby">Sort by: </label>
132
        <label for="orderby">Sort by: </label>
121
        <select name="orderby" id="orderby">
133
        <select name="orderby" id="orderby">
122
- 

Return to bug 36616