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