Sha256: b3176ff294855e0897335d056d90fa285a46769473757d978bea4fdf20f9b769
Contents?: true
Size: 478 Bytes
Versions: 1
Compression:
Stored size: 478 Bytes
Contents
module ForestRails class ApimapsController < ForestRails::ApplicationController def index result = [] ActiveRecord::Base.connection.tables.map do |model_name| begin model = model_name.classify.constantize result << SchemaAdapter.new(model).perform rescue => error puts error.inspect end end render json: result, each_serializer: ApimapSerializer, adapter: :json_api end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
forest_rails-0.0.4 | app/controllers/forest_rails/apimaps_controller.rb |