Bug 8906: Followup FIX hardcoded localhost url
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / oai_sets.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Administration &rsaquo; [% IF ( op_new ) %]OAI sets configuration &rsaquo; Add a new OAI set[% ELSE %]OAI sets configuration[% END %]</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4 <script type="text/javascript">
5 //<![CDATA[
6 function newDescField() {
7     $("#adddescription").before(
8         '<li><label>setDescription: </label>' +
9         '<textarea style="vertical-align:middle" rows="2" cols="30" name="description"></textarea>' +
10         '<a onclick="delDescField(this); return false;" class="clear-field" href="#">Remove</a>' +
11         '</li>'
12     );
13 }
14
15 function delDescField(minusButton) {
16     var li = $(minusButton).parent('li');
17     $(li).remove();
18 }
19
20 $(document).ready(function() {
21     new YAHOO.widget.Button("newoaiset");
22 });
23 //]]>
24 </script>
25 </head>
26
27 <body id="admin_oai_sets" class="admin">
28 [% INCLUDE 'header.inc' %]
29 [% INCLUDE 'cat-search.inc' %]
30
31 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo; [% IF ( op_new ) %]<a href="/cgi-bin/koha/admin/oai_sets.pl">OAI sets configuration</a> &rsaquo; Add a new OAI set[% ELSIF ( op_mod ) %]<a href="/cgi-bin/koha/admin/oai_sets.pl">OAI sets configuration</a> &rsaquo; Modify OAI set '[% spec %]'[% ELSE %] OAI sets configuration[% END %]</div>
32
33 <div id="doc3" class="yui-t2">
34
35 <div id="bd">
36   <div id="yui-main">
37     <div class="yui-b">
38         [% IF ( op_new || op_mod ) %]
39             <form method="post" action="/cgi-bin/koha/admin/oai_sets.pl">
40             [% IF ( op_new ) %]
41                 <h2>Add a new OAI set</h2>
42                 <input type="hidden" name="op" value="savenew" />
43             [% ELSIF ( op_mod ) %]
44                 <h2>Modify OAI set '[% spec %]'</h2>
45                     <input type="hidden" name="op" value="savemod" />
46                     <input type="hidden" name="id" value="[% id %]" />
47             [% END %]
48                 <fieldset id="oaidetails" class="rows">
49                     <ol>
50                         <li>
51                             <label for="spec" class="required">setSpec: </label>
52                             <input type="text" id="spec" name="spec" value="[% spec %]" />
53                         </li>
54                         <li>
55                             <label for="name" class="required">setName: </label>
56                             <input type="text" id="name" name="name" value="[% name %]" />
57                         </li>
58                         [% FOREACH desc IN descriptions %]
59                             <li>
60                                 <label>setDescription: </label>
61                                 <textarea style="vertical-align:middle" rows="2" cols="30" name="description">[% desc.description %]</textarea>
62                                 <a onclick="delDescField(this); return false;" class="clear-field" href="#">Remove</a>
63                             </li>
64                         [% END %]
65                         <li id="adddescription"><span class="label">&nbsp;</span><a class="clone-field" href="#" onclick='newDescField(); return false;'>Add description</a></li>
66
67                     </ol>
68                 </fieldset>
69                 <fieldset class="action">
70                     <input type="submit" value="Save" /> <a class="cancel" href="/cgi-bin/koha/admin/oai_sets.pl">Cancel</a>
71                 </fieldset>
72             </form>
73         [% ELSE %]
74
75         <div id="toolbar">
76             <ul class="toolbar">
77             <li><a id="newoaiset" href="/cgi-bin/koha/admin/oai_sets.pl?op=new">New set</a></li>
78         </ul></div>
79
80         <h2>OAI sets</h2>
81         [% IF sets_loop %]
82             <table>
83                 <thead>
84                     <tr>
85                         <th>setSpec</th>
86                         <th>setName</th>
87                         <th>setDescriptions</th>
88                         <th>Action</th>
89                     </tr>
90                 </thead>
91                 <tbody>
92                     [% FOREACH set IN sets_loop %]
93                         <tr>
94                             <td>[% set.spec %]</td>
95                             <td>[% set.name %]</td>
96                             <td>
97                                 [% IF set.descriptions %]
98                                     <ul>
99                                         [% FOREACH desc IN set.descriptions %]
100                                             <li>[% desc.description %]</li>
101                                         [% END %]
102                                     </ul>
103                                 [% ELSE %]
104                                     <em>No descriptions</em>
105                                 [% END %]
106                             </td>
107                             <td>
108                                 <a href="/cgi-bin/koha/admin/oai_sets.pl?op=mod&amp;id=[% set.id %]">Modify</a>
109                                 |
110                                 <a href="/cgi-bin/koha/admin/oai_sets.pl?op=del&amp;id=[% set.id %]">Delete</a>
111                                 |
112                                 <a href="/cgi-bin/koha/admin/oai_set_mappings.pl?id=[% set.id %]">Define mappings</a>
113                             </td>
114                         </tr>
115                     [% END %]
116                 </tbody>
117             </table>
118         [% ELSE %]
119             <div class="dialog message"><p>There are no sets defined.</p></div>
120         [% END %]
121         [% END %]
122
123     </div>
124   </div>
125   <div class="yui-b">
126     [% INCLUDE 'admin-menu.inc' %]
127   </div>
128 </div>
129 [% INCLUDE 'intranet-bottom.inc' %]