Class | Admin::RoomManagersController
In: | app/controllers/admin/room_managers_controller.rb
Parent: | Admin::BaseController

### Methods

create edit index new show update

### Public Instance methods

create()

[Source]

        # File app/controllers/admin/room_managers_controller.rb, line 11
    11:   def create
    12:     @room_manager = RoomManager.new(params[:room_manager])
    13:     if @room_manager.save
    14:       flash[:notice] = "El responsable se ha guardado correctamente"
    15:       redirect_to admin_room_managers_path
    16:     else
    17:       render :action => :new
    18:     end
    19:   end

edit()

[Source]

        # File app/controllers/admin/room_managers_controller.rb, line 25
    25:   def edit
    26:     @room_manager = RoomManager.find(params[:id])
    27:   end

index()

[Source]

       # File app/controllers/admin/room_managers_controller.rb, line 3
    3:   def index
    4:     @room_managers = RoomManager.find(:all, :order => "lower(tildes(name))")
    5:   end

new()

[Source]

       # File app/controllers/admin/room_managers_controller.rb, line 7
    7:   def new
    8:     @room_manager = RoomManager.new
    9:   end

show()

[Source]

        # File app/controllers/admin/room_managers_controller.rb, line 21
    21:   def show
    22:     @room_manager = RoomManager.find(params[:id])
    23:   end

update()

[Source]

        # File app/controllers/admin/room_managers_controller.rb, line 29
    29:   def update
    30:     @room_manager = RoomManager.find(params[:id])
    31:     if @room_manager.update_attributes(params[:room_manager])
    32:       flash[:notice] = "El responsable se ha guardado correctamente"
    33:       redirect_to admin_room_managers_path
    34:     else
    35:       render :action => :edit
    36:     end
    37:   end

[Validate]