Class: Addresses::NeighborhoodsController

Inherits:
ApplicationController show all
Defined in:
app/controllers/addresses/neighborhoods_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



7
8
9
10
11
12
13
# File 'app/controllers/addresses/neighborhoods_controller.rb', line 7

def index
  @city = City.find(params[:city_id])

  @neighborhoods = @city.neighborhoods.order('name asc')

  render json: @neighborhoods
end