Bug 23129: (RM follow-up) Fix failing test
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / authorities / detail.tt
1 [% PROCESS 'authorities.inc' %]
2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha &rsaquo; Authorities &rsaquo;
4     [% IF ( unknownauthid ) %]
5       Unknown authority record
6     [% ELSE %]
7       Details for authority #[% authid %] ([% authtypetext %])
8     [% END %]
9 </title>
10 [% INCLUDE 'doc-head-close.inc' %]
11 [% IF ( displayhierarchy ) %]
12 <script type="text/javascript" src="/intranet-tmpl/lib/jquery/plugins/jquery.jstree.js"></script>
13 [% END %]
14 <script type="text/javascript">
15
16 //<![CDATA[
17
18          $(document).ready(function() {
19     $('#authoritiestabs').tabs();
20     [% IF ( displayhierarchy ) %]
21         var current_nodes = [];
22         $('.currentauth').each(function() {
23             current_nodes.push('#' + $(this).parent().parents('li:first').attr('id'));
24             });
25         $('#hierarchies').jstree({
26                 "plugins": [ "themes", "html_data"],
27                 "themes": { "theme": "classic",
28                             "icons": false },
29                 "core": { "initially_open": current_nodes }
30             });
31     [% END %]
32          });
33
34 function confirm_deletion() {
35     var is_confirmed = confirm(_("Are you sure you want to delete this authority?"));
36     if (is_confirmed) {
37         window.location="authorities-home.pl?op=delete&authid=[% authid %]";
38     }
39 }
40 function Dopop(link) {
41         newin=window.open(link,'width=500,height=400,toolbar=false,scrollbars=yes');
42 }
43 //]]>
44 </script>
45 <script type="text/javascript">
46 function Help() {
47     newin=window.open("/cgi-bin/koha/help.pl","KohaHelp",'width=600,height=600,toolbar=false,scrollbars=yes');
48 }
49
50 function addauthority() {
51     X = document.forms[0].authtype.value;
52     window.location="/cgi-bin/koha/authorities/authorities.pl?authtypecode="+X;
53 }
54 function searchauthority() {
55     X = document.forms[0].authtype2.value;
56     Y = document.forms[0].value.value;
57     window.location="/cgi-bin/koha/authorities/authorities-home.pl?op=do_search&type=intranet&authtypecode="+X+"&value="+Y+"&marclist=&and_or=and&excluding=&operator=contains";
58 }
59 </script>
60 </head>
61 <body id="auth_detail" class="auth">
62 [% INCLUDE 'header.inc' %]
63 [% INCLUDE 'authorities-search.inc' %]
64 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/authorities/authorities-home.pl">Authorities</a> &rsaquo;
65     [% IF ( unknownauthid ) %]
66       Unknown authority record
67     [% ELSE %]
68       Details for authority #[% authid %] ([% authtypetext %])
69     [% END %]
70 </div>
71
72 <div id="doc" class="yui-t7">
73
74 <div id="bd">
75         <div id="yui-main">
76         <div class="yui-g">
77
78     [% INCLUDE 'authorities-toolbar.inc' %]
79         
80 [% IF ( displayhierarchy ) %]
81 <div id="hierarchies">
82 [% PROCESS showhierarchy trees = loophierarchies %]
83 </div>
84 [% END %]
85
86
87 [% IF ( unknownauthid ) %]
88     <div class="dialog message">The authority record you requested does not exist ([% errauthid %]).</div>
89 [% ELSE %]
90 <h1>Authority #[% authid %] ([% authtypetext %])</h1>
91
92 <div id="action">
93     [% IF count > 0 %]
94         Used in <a href="/cgi-bin/koha/catalogue/search.pl?type=intranet&amp;op=do_search&amp;q=an=[% authid %]">[% count %] record(s)</a>
95     [% ELSE %]
96         This authority is not used in any records.
97     [% END %]
98 </div>
99
100 <div id="authoritiestabs" class="toptabs numbered">
101     <ul>
102         [% FOREACH BIG_LOO IN BIG_LOOP %]
103             <li>
104                 <a href="#tab[% BIG_LOO.number %]XX">[% BIG_LOO.number %]</a>
105             </li>
106         [% END %]
107     </ul>
108
109 [% FOREACH BIG_LOO IN BIG_LOOP %]
110     <div id="tab[% BIG_LOO.number %]XX">
111     [% FOREACH innerloo IN BIG_LOO.innerloop %]
112         [% IF ( innerloo.tag ) %]
113             <div class="tag">
114             <div class="tag_title">
115                 [% innerloo.tag %]
116             </div>
117         [% ELSE %]
118             <div class="tag">
119         [% END %]
120         [% FOREACH subfiel IN innerloo.subfield %]
121             <p>
122                 <label class="labelsubfield">&nbsp;
123                 [% UNLESS ( subfiel.hide_marc ) %]<b>[% subfiel.marc_subfield %]</b>[% END %]
124                 <span title="[% subfiel.long_desc %]">[% subfiel.short_desc %]</span></label>
125                 [% subfiel.marc_value %]
126                 [% IF ( subfiel.link ) %]
127                     <a href="/cgi-bin/koha/catalogue/search.pl?op=do_search&amp;marclist=[% subfiel.link %]&amp;operator==&amp;type=intranet&amp;value=[% subfiel.marc_value |url %]">
128                         <img border="0" src="[% interface %]/[% theme %]/images/filefind.png" height="15" title="Search on [% subfiel.marc_value %]">
129                     </a>
130                 [% END %]
131                 [% IF ( subfiel.authority ) %]
132                     <a href="/cgi-bin/koha/authorities/detail.pl?authid=[% subfiel.authority %]" class="button">Auth</a>
133                 [% END %]
134             </p>
135         [% END %]
136         </div>
137     [% END %]
138     </div>
139 [% END %]
140 </div>
141 </div>
142 </div>
143 [% END %]
144 </div>
145
146 [% INCLUDE 'intranet-bottom.inc' %]