Sha256: 57e8c973ef343bd76bbec8e06cfb1da700601714648134dd35248a0fde0c6096

Contents?: true

Size: 456 Bytes

Versions: 1

Compression:

Stored size: 456 Bytes

Contents

module Admin

  module SearchHelper

    def search(resource = @resource)
      if (typus_search = resource.typus_defaults_for(:search)) && typus_search.any?
        search_params = params.dup
        %w(action controller id search page utf8).each { |p| search_params.delete(p) }
        options = { :hidden_params => search_params.map { |k, v| hidden_field_tag(k, v) } }
        render "admin/helpers/search/search", options
      end
    end

  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
typus-3.0.4 app/helpers/admin/search_helper.rb