@@ -, +, @@ used in edit mode x records. authority is linked is missing. is used that authority --- authorities/authorities.pl | 5 ++++- .../prog/en/modules/authorities/authorities.tt | 8 +++++++- 2 files changed, 11 insertions(+), 2 deletions(-) --- a/authorities/authorities.pl +++ a/authorities/authorities.pl @@ -557,13 +557,16 @@ if(!$authtypecode) { $authtypecode = $authid ? Koha::Authorities->find($authid)->authtypecode : ''; } +my $authobj = Koha::Authorities->find($authid); +my $count = $authobj ? $authobj->get_usage_count : 0; + my ($template, $loggedinuser, $cookie) = get_template_and_user({template_name => "authorities/authorities.tt", query => $input, type => "intranet", flagsrequired => {editauthorities => 1}, }); -$template->param(nonav => $nonav,index=>$myindex,authtypecode=>$authtypecode,breedingid=>$breedingid); +$template->param(nonav => $nonav,index=>$myindex,authtypecode=>$authtypecode,breedingid=>$breedingid, count=>$count); $tagslib = GetTagsLabels(1,$authtypecode); $mandatory_z3950 = GetMandatoryFieldZ3950($authtypecode); --- a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt @@ -263,7 +263,13 @@ [% END %] - +
+ [% IF count %] + Used in [% count | html %] record(s) + [% ELSE %] + This authority is not used in any records. + [% END %] +