diff --git a/app/controllers/admin/eventtype_controller.rb b/app/controllers/admin/eventtypes_controller.rb similarity index 68% rename from app/controllers/admin/eventtype_controller.rb rename to app/controllers/admin/eventtypes_controller.rb index 125af325..53d48797 100644 --- a/app/controllers/admin/eventtype_controller.rb +++ b/app/controllers/admin/eventtypes_controller.rb @@ -1,17 +1,17 @@ -class Admin::EventtypeController < ApplicationController +class Admin::EventtypesController < ApplicationController before_filter :verify_organizer def show - render :eventtype_list + render :eventtypes end def update @conference.update_attributes!(params[:conference]) - redirect_to(admin_conference_eventtype_path( + redirect_to(admin_conference_eventtypes_path( conference_id: @conference.short_title), notice: 'Event types were successfully updated.') rescue Exception => e - redirect_to(admin_conference_eventtype_path( + redirect_to(admin_conference_eventtypes_path( conference_id: @conference.short_title), alert: 'Event types update failed: #{e.message}') end diff --git a/app/views/admin/conference/_sidebar.html.haml b/app/views/admin/conference/_sidebar.html.haml index c4e8b1e0..769e4532 100644 --- a/app/views/admin/conference/_sidebar.html.haml +++ b/app/views/admin/conference/_sidebar.html.haml @@ -10,8 +10,8 @@ = link_to "Rooms", admin_conference_rooms_path(@conference.short_title) %li{:class=> active_nav_li(admin_conference_tracks_path(@conference.short_title))} = link_to "Tracks", admin_conference_tracks_path(@conference.short_title) - %li{:class=> active_nav_li(admin_conference_eventtype_index_path(@conference.short_title))} - = link_to "Event Types", admin_conference_eventtype_index_path(@conference.short_title) + %li{:class=> active_nav_li(admin_conference_eventtypes_path(@conference.short_title))} + = link_to "Event Types", admin_conference_eventtypes_path(@conference.short_title) %li{:class=> active_nav_li(admin_conference_difficulty_levels_path(@conference.short_title))} = link_to "Difficulty Levels", admin_conference_difficulty_levels_path(@conference.short_title) %li{:class=> active_nav_li(admin_conference_social_events_path(@conference.short_title))} diff --git a/app/views/admin/eventtype/_event_type_fields.html.erb b/app/views/admin/eventtypes/_event_type_fields.html.erb similarity index 100% rename from app/views/admin/eventtype/_event_type_fields.html.erb rename to app/views/admin/eventtypes/_event_type_fields.html.erb diff --git a/app/views/admin/eventtype/event_type_list.html.haml b/app/views/admin/eventtypes/index.html.haml similarity index 100% rename from app/views/admin/eventtype/event_type_list.html.haml rename to app/views/admin/eventtypes/index.html.haml diff --git a/config/routes.rb b/config/routes.rb index e437fe45..eb88be3a 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -27,7 +27,7 @@ Osem::Application.routes.draw do resources :difficulty_levels, only: [:show, :update, :index] resources :rooms, only: [:show, :update, :index] resources :tracks, only: [:show, :update, :index] - resources :eventtype, only: [:show, :update, :index] + resources :eventtypes, only: [:show, :update, :index] resources :social_events, only: [:show, :update, :index] resources :supporter_levels, only: [:show, :update, :index] resources :emails, only: [:show, :update, :index]