Merge remote-tracking branch 'kc/new/bug_5616' into kcmaster
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / fieldmapping.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Administration &rsaquo; Keyword to MARC Mapping</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4
5 <script type="text/javascript">
6 //<![CDATA[
7 $(document).ready(function() {
8         $('#selectframework').find("input:submit").hide();
9         $('#framework').change(function() {
10                 $('#selectframework').submit();
11         });
12 });
13 //]]>
14 </script>
15
16
17 </head>
18
19 <body>
20 [% INCLUDE 'header.inc' %]
21 [% INCLUDE 'cat-search.inc' %]
22 <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; Keyword to MARC Mapping</div>
23 <div id="doc3" class="yui-t2">
24         <div id="yui-main">
25                 <div class="yui-b">
26                         <h2>Keyword to MARC Mapping</h2>
27                         [% UNLESS ( fields ) %]
28                         <div class="dialog message"><p>There are no mappings for the [% IF ( frameworktext ) %]<em>[% frameworktext %]</em>[% ELSE %]default[% END %] framework. </p></div>
29                         [% END %]
30                         <form method="get" action="/cgi-bin/koha/admin/fieldmapping.pl" id="selectframework">
31                                 <label for="framework">Framework:</label>
32                                 <select name="framework" id="framework" style="width:20em;">
33                                         <option value="">Default</option>
34                                 [% FOREACH frameworkloo IN frameworkloop %]
35                                         [% IF ( frameworkloo.selected ) %]
36                                         <option selected="selected" value="[% frameworkloo.value %]">[% frameworkloo.frameworktext %]</option>
37                                         [% ELSE %]
38                                         <option value="[% frameworkloo.value %]">[% frameworkloo.frameworktext %]</option>
39                                         [% END %]
40                                 [% END %]
41                                 </select>
42                         <input type="submit" value="Go" />
43                         </form>
44
45
46                         <form method="post" action="" id="addfield">
47                                 <input type="hidden" name="framework" value="[% framework %]" />
48                                 <fieldset class="rows">
49                                 <legend>Add a mapping</legend>
50                                 <ol>
51                                         <li><label for="fieldname">Field name: </label><input type="text" id="fieldname" name="fieldname" /></li>
52                                         <li><label for="marcfield">MARC field: </label><input type="text" id="marcfield" name="marcfield" size="3" /></li>
53                                         <li><label for="marcsubfield">MARC subfield: </label><input type="text" id="marcsubfield" name="marcsubfield" size="1" /></li>
54                                 </ol>
55                                 <fieldset class="action">
56                                         <input type="submit" value="Submit" />
57                                 </fieldset>
58                                 </fieldset>
59                         </form>
60
61                                 [% IF ( fields ) %]<table>
62                                                                 <caption>Mappings for the [% IF ( frameworktext ) %]<em>[% frameworktext %]</em>[% ELSE %]default[% END %] framework</caption>
63                                                                         <tr>
64                                                                                 <th>Field</th>
65                                                                                 <th>MARC Field</th>
66                                                                                 <th>MARC Subfield</th>
67                                                                                 <th>&nbsp;</th>
68                                                                         </tr>
69                                                                         [% FOREACH field IN fields %]
70                                                                         <tr>
71                                                                                 <td>[% field.field %]</td>
72                                                                                 <td>[% field.fieldcode %]</td>
73                                                                                 <td>[% field.subfieldcode %]</td>
74                                                                                 <td><a href="?op=delete&amp;id=[% field.id %]&amp;framework=[% field.framework %]">Delete</a></td>
75                                                                         </tr>
76                                                                         [% END %]
77                                                                 </table>[% END %]
78
79
80                 </div>
81         </div>
82
83         <div class="yui-b">
84                 [% INCLUDE 'admin-menu.inc' %]
85         </div>
86 </div>
87 [% INCLUDE 'intranet-bottom.inc' %]