Class: Decidim::TermCustomizer::Constraint
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Decidim::TermCustomizer::Constraint
- Defined in:
- app/models/decidim/term_customizer/constraint.rb
Instance Method Summary collapse
Instance Method Details
#component ⇒ Object
13 14 15 |
# File 'app/models/decidim/term_customizer/constraint.rb', line 13 def component subject if subject.is_a?(Decidim::Component) end |
#manifest ⇒ Object
23 24 25 26 27 28 29 |
# File 'app/models/decidim/term_customizer/constraint.rb', line 23 def manifest space_class = space ? space.class.name : subject_type Decidim.participatory_space_manifests.find do |manifest| manifest.model_class_name == space_class end end |
#manifest_name ⇒ Object
31 32 33 |
# File 'app/models/decidim/term_customizer/constraint.rb', line 31 def manifest_name manifest.try(:name) end |
#space ⇒ Object
17 18 19 20 21 |
# File 'app/models/decidim/term_customizer/constraint.rb', line 17 def space return component.participatory_space if component subject end |