Class: DbsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- DbsController
- Defined in:
- lib/tamplates/dbs_controller.rb
Instance Method Summary collapse
Instance Method Details
#show ⇒ Object
3 4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/tamplates/dbs_controller.rb', line 3 def show @name = params[:id] @model_name = @name.capitalize @content = eval(@model_name).all respond_to do |format| format.html # show.html.erb format.json { render json: @content } end end |