Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
15 lines (11 sloc) 286 Bytes
class CompaniesController < ApplicationController
def index
render json: Company.all
end
def create
create_params = ActiveModelSerializers::Deserialization.jsonapi_parse(
params, only: [:name, :logo]
)
render json: Company.create(create_params)
end
end