I have a model Userthat has some photos. I want to configure the checkbox filter in Active Admin to filter those users who have photos. In principle, where there is an association of photographs.
class User < ActiveRecord::Base
has_many :photos
end
Is there an easy way to do this? I know that you can filter users who have a specific photo, etc., but I have not seen an example where you can filter by presence.
source
share