I want to hide or remove 'any' from select option based on user role... is there any way to do that?
this is what i tried
filter :product_type, :as=>:select, :include_blank =>false, :collection => ['a','b','c'] ...but no effect
in case...
following is the code for hiding 'any' from all select option in activeadmin
module ActiveAdmin
module Inputs
class FilterSelectInput < ::Formtastic::Inputs::SelectInput
def input_options
super.merge(:include_blank => false)
end
end
end
end
put this code in initializer/active_admin.rb
I want to hide or remove 'any' from select option based on user role... is there any way to do that?
this is what i tried
filter :product_type, :as=>:select, :include_blank =>false, :collection => ['a','b','c'] ...but no effect
in case...
following is the code for hiding 'any' from all select option in activeadmin
module ActiveAdmin
module Inputs
class FilterSelectInput < ::Formtastic::Inputs::SelectInput
def input_options
super.merge(:include_blank => false)
end
end
end
end
put this code in initializer/active_admin.rb