Class: Decidim::Assemblies::OrganizationPrioritizedAssemblies
- Inherits:
-
Query
- Object
- Query
- Decidim::Assemblies::OrganizationPrioritizedAssemblies
- Defined in:
- app/queries/decidim/assemblies/organization_prioritized_assemblies.rb
Overview
This query class filters public assemblies given an organization in a meaningful prioritized order.
Instance Method Summary collapse
-
#initialize(organization, user = nil) ⇒ OrganizationPrioritizedAssemblies
constructor
A new instance of OrganizationPrioritizedAssemblies.
- #query ⇒ Object
Constructor Details
#initialize(organization, user = nil) ⇒ OrganizationPrioritizedAssemblies
Returns a new instance of OrganizationPrioritizedAssemblies.
8 9 10 11 |
# File 'app/queries/decidim/assemblies/organization_prioritized_assemblies.rb', line 8 def initialize(organization, user = nil) @organization = organization @user = user end |
Instance Method Details
#query ⇒ Object
13 14 15 16 17 18 |
# File 'app/queries/decidim/assemblies/organization_prioritized_assemblies.rb', line 13 def query Decidim::Query.merge( OrganizationPublishedAssemblies.new(@organization, @user), PrioritizedAssemblies.new ).query end |