diff --git a/app/controllers/item_zone_sets_controller.rb b/app/controllers/item_zone_sets_controller.rb new file mode 100644 index 00000000..6ad3fe37 --- /dev/null +++ b/app/controllers/item_zone_sets_controller.rb @@ -0,0 +1,5 @@ +class ItemZoneSetsController < ApplicationController + def index + render :json => Zone::ItemZoneSets.keys.sort.as_json, :callback => params[:callback] + end +end diff --git a/app/helpers/item_zone_sets_helper.rb b/app/helpers/item_zone_sets_helper.rb new file mode 100644 index 00000000..4aabf267 --- /dev/null +++ b/app/helpers/item_zone_sets_helper.rb @@ -0,0 +1,2 @@ +module ItemZoneSetsHelper +end diff --git a/config/routes.rb b/config/routes.rb index 3fd984fc..7fa82fa1 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -8,4 +8,6 @@ OpenneoImpressItems::Application.routes.draw do |map| match '/pet_types/:pet_type_id/swf_assets.json' => 'swf_assets#index', :as => :pet_type_swf_assets match '/species/:species_id/color/:color_id/pet_type.json' => 'pet_types#show' + + match '/item_zone_sets.js' => 'ItemZoneSets#index' end diff --git a/spec/controllers/item_zone_sets_controller_spec.rb b/spec/controllers/item_zone_sets_controller_spec.rb new file mode 100644 index 00000000..31b7341c --- /dev/null +++ b/spec/controllers/item_zone_sets_controller_spec.rb @@ -0,0 +1,5 @@ +require 'spec_helper' + +describe ItemZoneSetsController do + +end