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

(-)a/authorities/authorities.pl (-1 / +2 lines)
Lines 660-671 if ($op eq "duplicate") Link Here
660
660
661
my $authority_types = Koha::Authority::Types->search( {}, { order_by => ['authtypetext'] } );
661
my $authority_types = Koha::Authority::Types->search( {}, { order_by => ['authtypetext'] } );
662
662
663
my $type = $authority_types->find($authtypecode);
663
$template->param(
664
$template->param(
664
    authority_types => $authority_types,
665
    authority_types => $authority_types,
665
    authtypecode    => $authtypecode,
666
    authtypecode    => $authtypecode,
666
    authid          => $authid,
667
    authid          => $authid,
667
    linkid          => $linkid,
668
    linkid          => $linkid,
668
    authtypetext    => $authority_types->find($authtypecode)->authtypetext,
669
    authtypetext    => $type ? $type->authtypetext : "",
669
    hide_marc       => C4::Context->preference('hide_marc'),
670
    hide_marc       => C4::Context->preference('hide_marc'),
670
);
671
);
671
output_html_with_http_headers $input, $cookie, $template->output;
672
output_html_with_http_headers $input, $cookie, $template->output;
(-)a/authorities/detail.pl (-4 / +5 lines)
Lines 178-184 my ($template, $loggedinuser, $cookie) = get_template_and_user( Link Here
178
178
179
my $authid = $query->param('authid');
179
my $authid = $query->param('authid');
180
180
181
my $authtypecode = Koha::Authorities->find($authid)->authtypecode;
181
my $authobj = Koha::Authorities->find($authid);
182
my $authtypecode = $authobj ? $authobj->authtypecode : q{};
182
$tagslib = &GetTagsLabels(1,$authtypecode);
183
$tagslib = &GetTagsLabels(1,$authtypecode);
183
184
184
# Build list of authtypes for showing them
185
# Build list of authtypes for showing them
Lines 209-223 my $biblio_fields; Link Here
209
while (my ($tagfield) = $sth->fetchrow) {
210
while (my ($tagfield) = $sth->fetchrow) {
210
	$biblio_fields.= $tagfield."9,";
211
	$biblio_fields.= $tagfield."9,";
211
}
212
}
212
chop $biblio_fields;
213
chop $biblio_fields if $biblio_fields;
213
214
214
build_tabs ($template, $record, $dbh,"",$query);
215
build_tabs ($template, $record, $dbh,"",$query);
215
216
217
my $type = $authority_types->find($authtypecode);
216
$template->param(
218
$template->param(
217
    authid          => $authid,
219
    authid          => $authid,
218
    count           => $count,
220
    count           => $count,
219
    biblio_fields   => $biblio_fields,
221
    biblio_fields   => $biblio_fields,
220
    authtypetext    => $authority_types->find($authtypecode)->authtypetext,
222
    authtypetext    => $type ? $type->authtypetext: "",
221
    authtypecode    => $authtypecode,
223
    authtypecode    => $authtypecode,
222
    authority_types => $authority_types,
224
    authority_types => $authority_types,
223
    csrf_token      => Koha::Token->new->generate_csrf({ session_id => scalar $query->cookie('CGISESSID') }),
225
    csrf_token      => Koha::Token->new->generate_csrf({ session_id => scalar $query->cookie('CGISESSID') }),
224
- 

Return to bug 17380