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

(-)a/authorities/authorities.pl (-1 / +4 lines)
Lines 557-569 if(!$authtypecode) { Link Here
557
    $authtypecode = $authid ? Koha::Authorities->find($authid)->authtypecode : '';
557
    $authtypecode = $authid ? Koha::Authorities->find($authid)->authtypecode : '';
558
}
558
}
559
559
560
my $authobj = Koha::Authorities->find($authid);
561
my $count = $authobj ? $authobj->get_usage_count : 0;
562
560
my ($template, $loggedinuser, $cookie)
563
my ($template, $loggedinuser, $cookie)
561
    = get_template_and_user({template_name => "authorities/authorities.tt",
564
    = get_template_and_user({template_name => "authorities/authorities.tt",
562
                            query => $input,
565
                            query => $input,
563
                            type => "intranet",
566
                            type => "intranet",
564
                            flagsrequired => {editauthorities => 1},
567
                            flagsrequired => {editauthorities => 1},
565
                            });
568
                            });
566
$template->param(nonav   => $nonav,index=>$myindex,authtypecode=>$authtypecode,breedingid=>$breedingid);
569
$template->param(nonav   => $nonav,index=>$myindex,authtypecode=>$authtypecode,breedingid=>$breedingid, count=>$count);
567
570
568
$tagslib = GetTagsLabels(1,$authtypecode);
571
$tagslib = GetTagsLabels(1,$authtypecode);
569
$mandatory_z3950 = GetMandatoryFieldZ3950($authtypecode);
572
$mandatory_z3950 = GetMandatoryFieldZ3950($authtypecode);
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt (-2 / +7 lines)
Lines 263-269 Link Here
263
                            [% END %]
263
                            [% END %]
264
                        </div>
264
                        </div>
265
                    </div> <!-- /#toolbar -->
265
                    </div> <!-- /#toolbar -->
266
266
                    <div id="action">
267
                        [% IF count %]
268
                                Used in <a href="/cgi-bin/koha/catalogue/search.pl?type=intranet&amp;op=do_search&amp;q=an=[% authid | uri %]">[% count | html %] record(s)</a>
269
                        [% ELSE %]
270
                                This authority is not used in any records.
271
                        [% END %]
272
                    </div>
267
                    <div id="authoritytabs" class="toptabs numbered">
273
                    <div id="authoritytabs" class="toptabs numbered">
268
                        <ul>
274
                        <ul>
269
                            [% FOREACH BIG_LOO IN BIG_LOOP %]
275
                            [% FOREACH BIG_LOO IN BIG_LOOP %]
270
- 

Return to bug 20615