Class: Decidim::EnhancedTextwork::Admin::PreviewParticipatoryTextForm

Inherits:
Form
  • Object
show all
Defined in:
app/forms/decidim/enhanced_textwork/admin/preview_participatory_text_form.rb

Overview

A form object to be used when admin users want to review a collection of paragraphs from a participatory text.

Instance Method Summary collapse

Instance Method Details

#from_models(paragraphs) ⇒ Object



11
12
13
14
15
# File 'app/forms/decidim/enhanced_textwork/admin/preview_participatory_text_form.rb', line 11

def from_models(paragraphs)
  self.paragraphs = paragraphs.collect do |paragraph|
    Admin::ParticipatoryTextParagraphForm.from_model(paragraph)
  end
end

#paragraphs_attributes=(attributes) ⇒ Object



17
# File 'app/forms/decidim/enhanced_textwork/admin/preview_participatory_text_form.rb', line 17

def paragraphs_attributes=(attributes); end