[% INCLUDE 'doc-head-open.inc' %]
-<title>Koha › SRU Search fields mapping</title>
+<title>Koha › SRU search fields mapping</title>
[% INCLUDE 'doc-head-close.inc' %]
<script type="text/javascript">
<div id="custom-doc" class="yui-t7">
<div id="bd">
- <h1>Modify SRU Search fields mapping</h1>
+ <h1>Modify SRU search fields mapping</h1>
<form id="form01" method="post">
<fieldset class="rows">
- <legend>Legend </legend>
- <ul>
- <li>
- <label for="Title">Title: </label>
- <input id="title" type="text" value="[% mapping.title %]" />
- </li>
- <li>
- <label for="ISBN">ISBN: </label>
- <input id="isbn" type="text" value="[% mapping.isbn %]" />
- </li>
- <li>
- <label for="LCCall">LC Call No: </label>
- <input id="lccall" type="text" value="[% mapping.lccall %]" />
- </li>
- <li>
- <label for="Control number">Control no: </label>
- <input id="controlnumber" type="text" value="[% mapping.controlnumber %]" />
- </li>
- <li>
- <label for="Any">Any: </label>
- <input id="srchany" type="text" value="[% mapping.srchany %]" />
- </li>
- <li>
- <label for="Author">Author: </label>
- <input id="author" type="text" value="[% mapping.author %]" />
- </li>
- <li>
- <label for="ISSN">ISSN: </label>
- <input id="issn" type="text" value="[% mapping.issn %]" />
- </li>
- <li>
- <label for="Subject">Subject: </label>
- <input id="subject" type="text" value="[% mapping.subject %]" />
- </li>
- <li>
- <label for="Dewey">Dewey: </label>
- <input id="dewey" type="text" value="[% mapping.dewey %]" />
- </li>
- <li>
- <label for="Standard ID">Standard ID: </label>
- <input id="stdid" type="text" value="[% mapping.stdid %]" />
- </li>
-
- </ul>
+ <div class="yui-g">
+ <div class="yui-u first">
+ <ol>
+ <li>
+ <label for="title">Title: </label>
+ <input id="title" type="text" value="[% mapping.title %]" />
+ </li>
+ <li>
+ <label for="isbn">ISBN: </label>
+ <input id="isbn" type="text" value="[% mapping.isbn %]" />
+ </li>
+ <li>
+ <label for="lccall">LC call number: </label>
+ <input id="lccall" type="text" value="[% mapping.lccall %]" />
+ </li>
+ <li>
+ <label for="controlnumber">Control number: </label>
+ <input id="controlnumber" type="text" value="[% mapping.controlnumber %]" />
+ </li>
+ <li>
+ <label for="srchany">Any: </label>
+ <input id="srchany" type="text" value="[% mapping.srchany %]" />
+ </li>
+ </ol>
+ </div>
+ <div class="yui-u">
+ <ol>
+ <li>
+ <label for="author">Author: </label>
+ <input id="author" type="text" value="[% mapping.author %]" />
+ </li>
+ <li>
+ <label for="issn">ISSN: </label>
+ <input id="issn" type="text" value="[% mapping.issn %]" />
+ </li>
+ <li>
+ <label for="subject">Subject: </label>
+ <input id="subject" type="text" value="[% mapping.subject %]" />
+ </li>
+ <li>
+ <label for="dewey">Dewey: </label>
+ <input id="dewey" type="text" value="[% mapping.dewey %]" />
+ </li>
+ <li>
+ <label for="stdid">Standard ID: </label>
+ <input id="stdid" type="text" value="[% mapping.stdid %]" />
+ </li>
+ </ol>
+ </div>
+ </div>
</fieldset>
<fieldset class="action">
<input type="submit" value="Save" class="submit" />
// enable recordtype to include field in post
$('#recordtype').prop('disabled',false);
});
+ $("#servername").on("blur",function(){
+ toUC(this);
+ });
+ $("#modify_sru_fields").on("click",function(){
+ ModMapping();
+ });
});
function ModMapping () {
var map= $('#show_sru_fields').val();
- window.open('/cgi-bin/koha/admin/sru_modmapping.pl?mapping='+map,'popup','width=800,height=400,resizable=no,toolbar=false,scrollbars=no,top');
+ window.open('/cgi-bin/koha/admin/sru_modmapping.pl?mapping='+map,'popup','width=800,height=400,resizable=yes,toolbar=false,scrollbars=yes,top');
}
[% ELSE %]
$(document).ready(function() {
],
"sPaginationType": "four_button"
}));
+ $(".delete").on("click",function(e){
+ var servername = $(this).data("servername");
+ if( confirm( _("Are you sure you want to delete server %s?").format(servername) ) ) {
+ return true;
+ } else {
+ e.preventDefault();
+ }
+ });
});
- function ConfirmDelete(name,id) {
- if( confirm( _("Choose OK if you really want to delete server ")+
- name+'.')) {
- window.location="[% script_name %]?op=delete_confirmed&id="+id;
- }
- return false;
- }
[% END %]
//]]>
</script>
<input type="hidden" name="id" value="[% server.id %]" />
[% ELSE %]
<h1>New [% PROCESS ServerType %] server</h1>
- [% END %]
+ [% END %]
<fieldset class="rows">
<ol>
- <li><label for="name">Server name: </label><input type="text" name="servername" id="servername" size="65" maxlength="100" onblur="toUC(this)" value="[% server.servername | html %]"/></li>
+ <li><label for="name">Server name: </label>
+ <input type="text" name="servername" id="servername" size="65" maxlength="100" value="[% server.servername | html %]"/>
+ </li>
<li><label for="host" class="required">Hostname: </label> <input type="text" name="host" id="host" size="30" value="[% server.host %]" required="required" /> <span class="required">Required</span>
[% IF (server.servertype||type) == 'sru' %]
<li>
<label for="sru_fields">SRU Search fields mapping: </label>
<input type="hidden" name="sru_fields" id="sru_fields" value="[% server.sru_fields %]" />
- <input type="text" name="show_sru_fields" id="show_sru_fields" size="100" value="[% server.sru_fields %]" disabled/> <input type="button" value="Modify" onclick="ModMapping()" />
+ <input type="text" name="show_sru_fields" id="show_sru_fields" size="100" value="[% server.sru_fields %]" disabled="disabled" /> <input type="button" id="modify_sru_fields" value="Modify" />
</li>
[% END %]
<li>
<tbody>
[% FOREACH loo IN loop %]
<tr>
- <td><a href="[% loo.script_name %]?op=edit&id=[% loo.id %]">[% loo.servername %]</a></td><td>[% loo.host %]:[% loo.port %]</td><td>[% loo.db %]</td><td>[% loo.userid %]</td><td>[% IF loo.password %]########[% END %]</td><td>[% IF ( loo.checked ) %]Yes[% ELSE %]No[% END %]</td><td>[% loo.rank %]</td>
+ <td><a href="/cgi-bin/koha/admin/z3950servers.pl?op=edit&id=[% loo.id %]">[% loo.servername %]</a></td><td>[% loo.host %]:[% loo.port %]</td><td>[% loo.db %]</td><td>[% loo.userid %]</td><td>[% IF loo.password %]########[% END %]</td><td>[% IF ( loo.checked ) %]Yes[% ELSE %]No[% END %]</td><td>[% loo.rank %]</td>
<td>[% loo.syntax %]</td><td>[% loo.encoding %]</td><td>[% loo.timeout %]</td>
<td>[% IF ( loo.recordtype == 'biblio' ) %]
<span>Bibliographic</span>
Actions <b class="caret"></b>
</a>
<ul class="dropdown-menu pull-right" role="menu" aria-labelledby="reportactions[% savedreport.id %]">
- <li><a href="[% loo.script_name %]?op=edit&id=[% loo.id %]"><i class="fa fa-pencil"></i> Edit</a></li>
- <li><a href="[% loo.script_name %]?op=add&id=[% loo.id %]"><i class="fa fa-copy"></i> Copy</a></li>
- <li><a href="javascript:void(0);" onclick="ConfirmDelete('[% loo.servername | replace("['\"]","") %]','[% loo.id %]');"><i class="fa fa-remove"></i> Delete</a></li>
+ <li><a href="/cgi-bin/koha/admin/z3950servers.pl?op=edit&id=[% loo.id %]"><i class="fa fa-pencil"></i> Edit</a></li>
+ <li><a href="/cgi-bin/koha/admin/z3950servers.pl?op=add&id=[% loo.id %]"><i class="fa fa-copy"></i> Copy</a></li>
+ <li><a href="/cgi-bin/koha/admin/z3950servers.pl?op=delete_confirmed&id=[% loo.id %]" class="delete" data-servername="[% loo.servername %]"><i class="fa fa-remove"></i> Delete</a></li>
</ul>
</div>
</td>