Bug 20538: Fix 2 JS paths
[koha.git] / koha-tmpl / opac-tmpl / bootstrap / en / modules / opac-auth-detail.tt
1 [% USE Asset %]
2 [% USE Koha %]
3 [% PROCESS 'opac-authorities.inc' %]
4 [% INCLUDE 'doc-head-open.inc' %]
5 <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog &rsaquo; Authority search &rsaquo; [% summary.mainentry %][% IF authtypetext %] ([% authtypetext %])[% END %]</title>
6 [% INCLUDE 'doc-head-close.inc' %]
7 [% BLOCK cssinclude %][% END %]
8 </head>
9 [% INCLUDE 'bodytag.inc' bodyid='opac-authoritiesdetail' bodyclass='scrollto' %]
10 [% INCLUDE 'masthead.inc' %]
11
12     <div class="main">
13         <ul class="breadcrumb">
14             <li><a href="/cgi-bin/koha/opac-main.pl">Home</a> <span class="divider">&rsaquo;</span></li>
15             <li><a href="/cgi-bin/koha/opac-authorities-home.pl">Authority search</a> <span class="divider">&rsaquo;</span></li>
16             <li><a href="#">[% summary.mainentry %][% IF authtypetext %] ([% authtypetext %])[% END %]</a></li>
17         </ul>
18
19         <div class="container-fluid">
20             <div class="row-fluid">
21                 [% IF ( OpacNav || OpacNavBottom ) %]
22                     <div class="span2">
23                         <div id="navigation">
24                             [% INCLUDE 'navigation.inc' %]
25                         </div>
26                     </div>
27                     <div class="span10">
28                 [% ELSE %]
29                     <div class="span12">
30                 [% END %]
31                     <div id="userauthdetails" class="maincontent">
32                         <div id="views">
33                             <span class="view">
34                                 <span id="Normalview">Normal view</span>
35                             </span>
36                             <span class="view">
37                                 <a id="MARCview" href="/cgi-bin/koha/opac-authoritiesdetail.pl?authid=[% authid %]&amp;marc=1">MARC view</a>
38                             </span>
39                         </div>
40
41                         [% IF ( displayhierarchy ) %]
42                             <div id="hierarchies">
43                                 [% PROCESS showhierarchy trees = loophierarchies %]
44                             </div>
45                         [% END %]
46
47                         <h1>[% summary.mainentry %][% IF authtypetext %] ([% authtypetext %])[% END %]</h1>
48
49                         <div class="usedin">
50                             [% IF count %]<a href="/cgi-bin/koha/opac-search.pl?type=opac&amp;q=[% authid %]&amp;idx=an,phr">Number of records used in: [% count %]</a>[% ELSE %]This authority is not used in any records.[% END %]
51                         </div>
52
53                         <div class="authstanza">
54                             [% FOREACH authorize IN summary.authorized %]
55                                 <div class="heading authorized auth[% seefro.field %]">
56                                     <span class="label">Preferred form: </span>
57                                     <span class="authorized">[% authorize.heading %]</span>
58                                 </div>
59                             [% END %]
60                             [% PROCESS otherscript headings=summary.otherscript wantcategory='preferred' %]
61                         </div>
62
63                         [% IF summary.seefrom.size %]
64                             <div class="authstanza seefrom">
65                                 <div class="authstanzaheading">Used for/see from:</div>
66                                 <ul class="seefrom">
67                                     [% FOREACH seefro IN summary.seefrom %]
68                                         <li class="heading seefrom auth[% seefro.field %]">
69                                             [% IF seefro.type && seefro.type != 'seefrom' %]
70                                                 <span class="label">[% PROCESS authtypelabel type=seefro.type | trim %]:</span>
71                                             [% END %]
72                                             <span class="seefrom">[% PROCESS authheadingdisplay heading=seefro.heading search=seefrosearch authid=seefro.authid %]</span>
73                                         </li>
74                                     [% END %]
75                                     [% PROCESS otherscript headings=summary.otherscript wantcategory='seefrom' %]
76                                 </ul>
77                             </div>
78                         [% END %]
79
80                         [% IF summary.seealso.size %]
81                             <div class="authstanza seealso">
82                                 <div class="authstanzaheading">See also:</div>
83                                 <ul class="seelso">
84                                     [% FOREACH seeals IN summary.seealso %]
85                                         <li class="heading seealso auth[% seeals.field %]">
86                                             [% IF seeals.type && seeals.type != 'seealso' %]
87                                                 <span class="label">[% PROCESS authtypelabel type=seeals.type | trim %]:</span>
88                                             [% END %]
89                                             <span class="seealso">[% PROCESS authheadingdisplay heading=seeals.heading search=seeals.search authid=seeals.authid %]</span>
90                                         </li>
91                                     [% END %]
92                                     [% PROCESS otherscript headings=summary.otherscript wantcategory='seealso' %]
93                                 </ul>
94                             </div>
95                         [% END %]
96
97                         [% IF marcflavour == 'UNIMARC' && summary.otherscript %]
98                             <div class="authstanza">
99                                 <div class="authstanzaheading">Other forms:</div>
100                                 <ul>
101                                     [% FOREACH otherscrip IN summary.otherscript %]
102                                         <li>
103                                             [% PROCESS language lang=otherscrip.lang | trim %]:
104                                             <span class="otherscript">[% otherscrip.term %]</span>
105                                         </li>
106                                     [% END %]
107                                 </ul>
108                             </div>
109                         [% END %]
110
111                         <div id="authdescriptions" class="toptabs">
112                             <ul>
113                                 <li id="tab_descriptions"><a href="#descriptions">Notes</a></li>
114                             </ul>
115                             <div id="descriptions">
116                                 <div class="content_set">
117                                     [% FOREACH note IN summary.notes %]
118                                         <p class="note auth[% note.field %]">[% note.note %]</p>
119                                     [% END %]
120                                 </div>
121                             </div>
122                         </div>
123                     </div> <!-- / .#userauthdetails -->
124                 </div> <!-- / .span10/12 -->
125             </div> <!-- / .row-fluid -->
126         </div> <!-- / .container-fluid -->
127     </div> <!-- / .main -->
128
129 [% INCLUDE 'opac-bottom.inc' %]
130 [% BLOCK jsinclude %]
131 [% IF ( displayhierarchy ) %]
132     [% Asset.js("lib/jquery/plugins/jquery.jstree.js") %]
133 [% END %]
134 <script type="text/javascript">
135     //<![CDATA[
136         $(document).ready(function() {
137             $('#authdescriptions').tabs();
138             [% IF ( displayhierarchy ) %]
139                 var current_nodes = [];
140                 $('.currentauth').each(function() {
141                     current_nodes.push('#' + $(this).parent().parents('li:first').attr('id'));
142                     });
143                 $('#hierarchies').jstree({
144                         "plugins": [ "themes", "html_data"],
145                         "themes": { "theme": "classic",
146                                     "icons": false },
147                         "core": { "initially_open": current_nodes }
148                     });
149             [% END %]
150         });
151     //]]>
152 </script>
153 [% END %]