Sha256: 8f2c5e63666c2e03d1f7f6e16e8e61150d3d4b96cf679398d36ffd66a1452ecf

Contents?: true

Size: 596 Bytes

Versions: 5

Compression:

Stored size: 596 Bytes

Contents

class Main < Merb::Controller
  self._template_root = File.dirname(__FILE__) / ".." / "views"
  
  def index
    part TodoPart => :list
  end
  
  def index2
    part TodoPart => :one    
  end
  
  def index3
    part(TodoPart => :one) + part(TodoPart => :list)
  end
  
  def index4
    provides :xml, :js
    part(TodoPart => :formatted_output)
  end
  
  def part_with_params
    part(TodoPart => :part_with_params, :my_param => "my_value")
  end
  
  def part_within_view
    render
  end
  
  def parth_with_absolute_template
    part(TodoPart => :parth_with_absolute_template)
  end
  
end

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
merb-parts-0.9.4 spec/fixtures/controllers/main.rb
merb-parts-0.9.6 spec/fixtures/controllers/main.rb
merb-parts-0.9.5 spec/fixtures/controllers/main.rb
merb-parts-0.9.7 spec/fixtures/controllers/main.rb
thorero-parts-0.9.4 spec/fixtures/controllers/main.rb