Class: Decidim::ParticipatoryProcesses::VisibleParticipatoryProcesses
- Inherits:
-
Query
- Object
- Query
- Decidim::ParticipatoryProcesses::VisibleParticipatoryProcesses
- Defined in:
- app/queries/decidim/participatory_processes/visible_participatory_processes.rb
Overview
This query class filters participatory processes given a current_user.
Instance Method Summary collapse
-
#initialize(current_user) ⇒ VisibleParticipatoryProcesses
constructor
A new instance of VisibleParticipatoryProcesses.
- #query ⇒ Object
Constructor Details
#initialize(current_user) ⇒ VisibleParticipatoryProcesses
Returns a new instance of VisibleParticipatoryProcesses.
7 8 9 |
# File 'app/queries/decidim/participatory_processes/visible_participatory_processes.rb', line 7 def initialize(current_user) @current_user = current_user end |
Instance Method Details
#query ⇒ Object
11 12 13 |
# File 'app/queries/decidim/participatory_processes/visible_participatory_processes.rb', line 11 def query Decidim::ParticipatoryProcess.visible_for(@current_user) end |