Sha256: 860bf57fd0c2e64698f7b290f59064102914f05f6d67d758d73dc3d99d17e004

Contents?: true

Size: 328 Bytes

Versions: 1

Compression:

Stored size: 328 Bytes

Contents

module Gemgento
  class AddressesController < ApplicationController
    respond_to :html, :json

    layout -> { set_layout false }

    def region_options
      country = Country.find(params[:country_id])
      @regions = Region.where(country: country).map { |r| [r.name, r.id] }

      respond_with @regions
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
gemgento-2.8.0 app/controllers/gemgento/addresses_controller.rb