Skip to content

Instantly share code, notes, and snippets.

@yelinaung
Created July 1, 2013 17:45
Show Gist options
  • Save yelinaung/5902969 to your computer and use it in GitHub Desktop.
Save yelinaung/5902969 to your computer and use it in GitHub Desktop.
# Controller
def index
@locations = Location.all
respond_to do |format|
format.json { render json: @locations }
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment