app/services/decidim/assemblies/assembly_search.rb in decidim-assemblies-0.20.1 vs app/services/decidim/assemblies/assembly_search.rb in decidim-assemblies-0.21.0
- old
+ new
@@ -6,13 +6,13 @@
class AssemblySearch < ParticipatorySpaceSearch
def initialize(options = {})
super(Assembly.all, options)
end
- def search_assembly_type
- return query if assembly_type == "all"
+ def search_type_id
+ return query if type_id.blank?
- query.where(assembly_type: assembly_type)
+ query.where(decidim_assemblies_type_id: type_id)
end
end
end
end