Sha256: 7d592f9ee2d0ba39fbb876de1c45605a53de95def7e6028ba6a614ce327c2eb2
Contents?: true
Size: 727 Bytes
Versions: 64
Compression:
Stored size: 727 Bytes
Contents
# frozen_string_literal: true module Decidim module Initiatives # Class uses to retrieve the available initiative types. class InitiativeTypes < Rectify::Query # Syntactic sugar to initialize the class and return the queried objects. # # organization - Decidim::Organization def self.for(organization) new(organization).query end # Initializes the class. # # organization - Decidim::Organization def initialize(organization) @organization = organization end # Retrieves the available initiative types for the given organization. def query InitiativesType.where(organization: @organization) end end end end
Version data entries
64 entries across 64 versions & 1 rubygems