Last active
March 28, 2016 23:02
-
-
Save perezpaya/96d8fa25644eb0249db3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CompanyController < ApplicationController | |
def index | |
render json: Company.all, | |
serializer: ActiveModel::Serializer::CollectionSerializer, | |
each_serializer: CompanySerializer | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment