2 <script type="text/javascript">
5 // prepare DOM for YUI Toolbar
7 $(document).ready(function() {
8 $("#newmenuc").empty();
9 $("#delAuthc").empty();
10 $("#savemenuc").empty();
14 // YUI Toolbar Functions
16 function yuiToolbar() {
19 [% FOREACH authtypesloo IN authtypesloop %]{ text: "[% authtypesloo.authtypetext %]", url: "/cgi-bin/koha/authorities/authorities.pl?authtypecode=[% authtypesloo.value %]"},
23 new YAHOO.widget.Button({
25 label: _("New authority"),
26 name: "newmenubutton",
31 var editButton = new YAHOO.widget.Button("editAuth");
33 var delAuthButton = new YAHOO.widget.Button({
37 container: "delAuthc",
38 onclick: {fn: confirm_deletion }
42 { text: _("MADS (XML)"), url: "/cgi-bin/koha/authorities/export.pl?format=mads&op=export&authid=[% authid %]" },
43 { text: _("MARCXML"), url: "/cgi-bin/koha/authorities/export.pl?format=marcxml&op=export&authid=[% authid %]" },
44 { text: _("MARC (non-Unicode/MARC-8)"), url: "/cgi-bin/koha/authorities/export.pl?format=marc8&op=export&authid=[% authid %]" },
45 { text: _("MARC (Unicode/UTF-8)"), url: "/cgi-bin/koha/authorities/export.pl?format=utf8&op=export&authid=[% authid %]" },
48 new YAHOO.widget.Button({
51 name: "savemenubutton",
53 container: "savemenuc"
59 <form name="f2" method="post" action="authorities.pl">
61 [% IF ( authid ) %] <a id="editAuth" href="authorities.pl?authid=[% authid %]">Edit</a>
63 [% UNLESS ( count ) %]
64 <span id="delAuthc"><a id="delAuth" href="javascript:confirm_deletion()">Delete</a></span>
66 <span id="savemenuc">Save</span>
67 [% ELSE %] [% END %]
70 <label for="add_authtypecode">New: </label>
71 <select id="add_authtypecode" name="authtypecode">
72 [% FOREACH authtypesloo IN authtypesloop %]
73 [% IF ( authtypesloo.selected ) %]
74 <option value="[% authtypesloo.value %]" selected="selected">[% authtypesloo.authtypetext %]</option>
76 <option value="[% authtypesloo.value %]">[% authtypesloo.authtypetext %]</option>
80 <input type="submit" value="Add" class="button" />