class School::Facility::LocationsController < ApplicationController
  def index
    render_success :ok, json: locations.map { |l| props(l) }
  end

  private
    def locations
      current_school.facility_locations.ordered
    end

    def props(location)
      {
        id: location.id,
        name: location.name
      }
    end
end
