Sha256: eb8353d60cd96a83df02b9f1eecd434e166cd2741e667d540a9685b5d79f471b
Contents?: true
Size: 510 Bytes
Versions: 22
Compression:
Stored size: 510 Bytes
Contents
module ActiveAdminAddons module RansackFormBuilderExtension def input(method, options = {}) if object.is_a?(::Ransack::Search) klass = object.klass if klass.respond_to?(:enumerized_attributes) && (attr = klass.enumerized_attributes[method]) options[:collection] ||= attr.options options[:as] = :select end end super(method, options) end end end ::Formtastic::FormBuilder.send :prepend, ActiveAdminAddons::RansackFormBuilderExtension
Version data entries
22 entries across 22 versions & 2 rubygems