Class: Effective::AddressesController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/effective/addresses_controller.rb

Instance Method Summary collapse

Instance Method Details

#subregionsObject


5
6
7
8
9
10
11
12
13
# File 'app/controllers/effective/addresses_controller.rb', line 5

def subregions
  @subregions = Carmen::Country.coded(params[:country_code]).try(:subregions)

  if @subregions.present?
    render partial: 'effective/addresses/subregions'
  else
    render body: "<option value=''>None Available</option>"
  end
end