Class: BardStatic::StaticController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/bard_static/static_controller.rb

Instance Method Summary collapse

Instance Method Details

#mockupsObject



6
7
8
9
# File 'app/controllers/bard_static/static_controller.rb', line 6

def mockups
  env["bard_static.prototype"] = true
  with_404_handler { render_with_index "mockups/#{params[:file_path]}", :layout => false }
end

#staticObject



11
12
13
14
# File 'app/controllers/bard_static/static_controller.rb', line 11

def static
  layout = !request.xhr? # render ajax responses with no layout
  with_404_handler { render_with_index "static/#{params[:file_path]}", :layout => layout }
end