diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc index 5b5a8828e8..fe94cf0f8b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc @@ -89,7 +89,8 @@ [% END %] - + +
  • diff --git a/koha-tmpl/intranet-tmpl/prog/js/auth-finder-search.js b/koha-tmpl/intranet-tmpl/prog/js/auth-finder-search.js index d986723664..5bdf7db81a 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/auth-finder-search.js +++ b/koha-tmpl/intranet-tmpl/prog/js/auth-finder-search.js @@ -9,7 +9,7 @@ $(document).ready(function(){ e.preventDefault(); finderjump('authorities.pl?index=' + index + '&authtypecode=' + authtypecode, 'full' ); }); - // marclist + // marclistanywhere $( "#value_any" ).autocomplete({ source: function(request, response) { $.ajax({ @@ -35,6 +35,40 @@ $(document).ready(function(){ } }); }, + select: function( event, ui ) { + $("#marclistanywhere").val("exact"); + }, + minLength: 3, + }); + // marclistheading + $( "#value_match" ).autocomplete({ + source: function(request, response) { + $.ajax({ + url: "/cgi-bin/koha/authorities/ysearch.pl", + dataType: "json", + data: { + authtypecode : authtypecode, + term: request.term, + op: "do_search", + type: "intranet", + and_or: "and", + operator: "start", + orderby: "HeadingAsc", + querytype: "match" + }, + success: function(data) { + response( $.map( data, function( item ) { + return { + label: item.summary, + value: item.summary + }; + })); + } + }); + }, + select: function( event, ui ) { + $("#marclistheading").val("exact"); + }, minLength: 3, }); // mainentry @@ -63,6 +97,9 @@ $(document).ready(function(){ } }); }, + select: function( event, ui ) { + $("#mainentry").val("exact"); + }, minLength: 3, }); // mainmainentry @@ -91,6 +128,9 @@ $(document).ready(function(){ } }); }, + select: function( event, ui ) { + $("#mainmainentry").val("exact"); + }, minLength: 3, }); $("#clear-form").click(function(){