Sha256: bb7244ee42ddb402d297a6db8de1d791a110912fed1f3a3a0e022267c5ebc66b

Contents?: true

Size: 1.02 KB

Versions: 6

Compression:

Stored size: 1.02 KB

Contents

<% search_url = url_for(params.merge(:controller => controller, :action => :browse, :page => 1, :update => 1, :escape => false)) -%>
<%# form_remote_tag :url => search_url, :method => :get,
  #                 :html => { :action => search_url, :id => record_select_search_id } do
  #                 %>
<% form_remote_tag :url => search_url, :method => :get, :html => { :action => search_url, :id => record_select_search_id } do %>
  <%= text_field_tag 'search', params[:search], :autocomplete => 'off', :class => 'text-input' %>
<% end %>

<script type="text/javascript">
//<![CDATA[
var record_select_search = jQuery(<%= ("#" + record_select_search_id).to_json %>);
if(record_select_search[0]) {
  record_select_search[0].onsubmit = function(_this) {
    _thisfrm = record_select_search;
    _this.ajaxGetSearh = jQuery.ajax({
      url: '<%=h search_url -%>',
      data: _thisfrm.serialize(),
      success: function(data) {
        eval(data);
        _this.highlightFirst();
      }
    });

    return false;
  };
};
//]]>
</script>

Version data entries

6 entries across 6 versions & 3 rubygems

Version Path
record_select-0.0.2 lib/views/_search.rhtml
record_select-0.0.1 lib/views/_search.rhtml
record_select-0.0.4 lib/views/_search.rhtml
record_select-0.0.3 lib/views/_search.rhtml
recordselect_custom-0.0.2 lib/views/_search.rhtml
recordselect-custom-0.0.1 lib/views/_search.rhtml