Class: Sprangular::CountriesController
- Inherits:
-
BaseController
- Object
- Spree::BaseController
- BaseController
- Sprangular::CountriesController
- Defined in:
- app/controllers/sprangular/countries_controller.rb
Instance Method Summary collapse
Methods inherited from BaseController
#invalid_resource!, #not_found, #unauthorized
Instance Method Details
#index ⇒ Object
2 3 4 5 6 7 8 |
# File 'app/controllers/sprangular/countries_controller.rb', line 2 def index @countries = Spree::Country.includes(:states).order(:name) render json: @countries, root: false, each_serializer: Sprangular::CountrySerializer end |