module Ecoportal module API class V2 class Page class Stages < Common::Content::CollectionModel class_resolver :stage_class, "Ecoportal::API::V2::Page::Stage" self.klass = :stage_class def get_by_name(name) find do |stage| stage.name.strip.downcase == name.to_s.strip.downcase end end def sections section_ids.map do |id| root.sections.find {|sec| sec.id == id} end end end end end end end