Module: Deltacloud::Helpers::Application::SinatraHelper
- Defined in:
- lib/deltacloud/helpers/deltacloud_helper.rb
Instance Method Summary collapse
Instance Method Details
#check_features(opts = {}) ⇒ Object
331 332 333 |
# File 'lib/deltacloud/helpers/deltacloud_helper.rb', line 331 def check_features(opts={}) Sinatra::Rabbit.set :check_features, opts[:for] end |
#new_route_for(route, &block) ⇒ Object
320 321 322 323 324 325 326 327 328 329 |
# File 'lib/deltacloud/helpers/deltacloud_helper.rb', line 320 def new_route_for(route, &block) get '/%s/new' % route.to_s do instance_eval(&block) if block_given? respond_to do |format| format.html do haml :"#{route}/new" end end end end |