Sha256: 6ac53dfebb115b22fd38ebf7c8754a2587586c1856910bca7c03a685022e7e99

Contents?: true

Size: 629 Bytes

Versions: 28

Compression:

Stored size: 629 Bytes

Contents

module GuideContainer
  extend ActiveSupport::Concern

  included do
    validates_presence_of :guide

    delegate :name,
             :language,
             :search_tags,
             :exercises,
             :first_exercise,
             :next_exercise,
             :stats_for,
             :exercises_count, to: :guide
  end

  def index_usage!(organization = Organization.current)
    organization.index_usage_of! guide, self
  end

  def friendly
    defaulting_name { "#{navigable_parent.friendly}: #{name}" }
  end

  def validate_accessible_for!(user)
  end

  def timed?
    false
  end

  def start!(user)
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
mumuki-laboratory-5.8.3 app/models/concerns/guide_container.rb
mumuki-laboratory-5.8.1 app/models/concerns/guide_container.rb
mumuki-laboratory-5.8.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.7.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.6.3 app/models/concerns/guide_container.rb
mumuki-laboratory-5.6.2 app/models/concerns/guide_container.rb
mumuki-laboratory-5.6.1 app/models/concerns/guide_container.rb
mumuki-laboratory-5.6.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.5.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.4.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.3.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.2.1 app/models/concerns/guide_container.rb
mumuki-laboratory-5.2.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.1.1 app/models/concerns/guide_container.rb
mumuki-laboratory-5.1.0 app/models/concerns/guide_container.rb
mumuki-laboratory-5.0.12 app/models/concerns/guide_container.rb
mumuki-laboratory-5.0.11 app/models/concerns/guide_container.rb
mumuki-laboratory-5.0.10 app/models/concerns/guide_container.rb
mumuki-laboratory-5.0.9 app/models/concerns/guide_container.rb
mumuki-laboratory-5.0.8 app/models/concerns/guide_container.rb