Lines 24-34
use C4::Auth qw( get_template_and_user );
Link Here
|
24 |
use C4::Output qw( output_html_with_http_headers ); |
24 |
use C4::Output qw( output_html_with_http_headers ); |
25 |
use C4::Context; |
25 |
use C4::Context; |
26 |
use C4::Breeding qw( Z3950Search Z3950SearchAuth ); |
26 |
use C4::Breeding qw( Z3950Search Z3950SearchAuth ); |
|
|
27 |
use C4::AuthoritiesMarc qw( GetAuthority); |
28 |
use MARC::Record; |
29 |
use Koha::Authorities; |
30 |
use Koha::Authority::Types; |
27 |
|
31 |
|
28 |
my $input = CGI->new; |
32 |
my $input = CGI->new; |
29 |
my $dbh = C4::Context->dbh; |
33 |
my $dbh = C4::Context->dbh; |
30 |
my $error = $input->param('error'); |
34 |
my $error = $input->param('error'); |
31 |
my $authid = $input->param('authid') || 0; |
35 |
my $authid = $input->param('authid') || 0; |
|
|
36 |
|
37 |
my $record = GetAuthority($authid); |
38 |
my $authobj = Koha::Authorities->find($authid); |
39 |
my $authtypecode = $authobj ? $authobj->authtypecode : ''; |
40 |
my $authority_type = Koha::Authority::Types->find($authtypecode); |
41 |
my $authtag = $authority_type->auth_tag_to_report; |
42 |
my $authfields = $authtag ? $record->field($authtag) : ''; |
32 |
my $nameany = $input->param('nameany'); |
43 |
my $nameany = $input->param('nameany'); |
33 |
my $authorany = $input->param('authorany'); |
44 |
my $authorany = $input->param('authorany'); |
34 |
my $authorcorp = $input->param('authorcorp'); |
45 |
my $authorcorp = $input->param('authorcorp'); |
Lines 45-50
my $index =$input->param('index');
Link Here
|
45 |
$page = $input->param('goto_page') if $input->param('changepage_goto'); |
56 |
$page = $input->param('goto_page') if $input->param('changepage_goto'); |
46 |
my $controlnumber = $input->param('controlnumber'); |
57 |
my $controlnumber = $input->param('controlnumber'); |
47 |
|
58 |
|
|
|
59 |
if (! $authorpersonal) { |
60 |
if ($authtag == 100) { |
61 |
$authorpersonal = $authfields->subfield('a'); |
62 |
} elsif ($authtag == 200) { |
63 |
$authorpersonal = $authfields->subfield('a'); |
64 |
} |
65 |
} |
66 |
|
67 |
if (! $authormeetingcon) { |
68 |
if ($authtag == 110) { |
69 |
$authormeetingcon = $authfields->subfield('a'); |
70 |
} elsif ($authtag == 210) { |
71 |
$authormeetingcon = $authfields->subfield('a'); |
72 |
} |
73 |
} |
74 |
|
75 |
if (! $uniformtitle) { |
76 |
if ($authtag == 130) { |
77 |
$uniformtitle = $authfields->subfield('a'); |
78 |
} elsif ($authtag == 230) { |
79 |
$uniformtitle = $authfields->subfield('a'); |
80 |
} |
81 |
} |
82 |
|
83 |
if (! $subject) { |
84 |
if ($authtag == 250) { |
85 |
$subject = $authfields->subfield('a'); |
86 |
} |
87 |
} |
88 |
|
48 |
my ( $template, $loggedinuser, $cookie ) = get_template_and_user({ |
89 |
my ( $template, $loggedinuser, $cookie ) = get_template_and_user({ |
49 |
template_name => "cataloguing/z3950_auth_search.tt", |
90 |
template_name => "cataloguing/z3950_auth_search.tt", |
50 |
query => $input, |
91 |
query => $input, |
51 |
- |
|
|