Sha256: 8a4cc2232d563570bb911b801c6a5f9cbc031c0f91a7ddaa6567dd691bd5a1ad

Contents?: true

Size: 520 Bytes

Versions: 54

Compression:

Stored size: 520 Bytes

Contents

# encoding: utf-8
class MagicAddresses::CountriesController < MagicAddresses::BaseController
  
  def index
    @countries = ::MagicAddresses::Country.includes(:translations).with_translations(I18n.locale).order( 'mgca_country_translations.name ASC' )
  end
  
  private

    # Never trust parameters from the scary internet, only allow the white list through.
    def instance_params
      params.require(:country).permit(:name, :default_name, :iso_code, :translations_attributes => [:id, :name, :locale])
    end

end

Version data entries

54 entries across 54 versions & 1 rubygems

Version Path
magic_addresses-0.0.34 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.33 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.32 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.31 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.30 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.29 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.28 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.27 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.26 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.25 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.24 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.23 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.22 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.21 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.20 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.19 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.18 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.17 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.16 lib/app/controllers/magic_addresses/countries_controller.rb
magic_addresses-0.0.15 lib/app/controllers/magic_addresses/countries_controller.rb