Class: Stay::Api::V1::RoomsController

Inherits:
BaseApiController
  • Object
show all
Defined in:
app/controllers/stay/api/v1/rooms_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



6
7
8
9
# File 'app/controllers/stay/api/v1/rooms_controller.rb', line 6

def index
    @rooms = @property.rooms
    render json: { rooms: @rooms }
end

#showObject



11
12
13
# File 'app/controllers/stay/api/v1/rooms_controller.rb', line 11

def show
    render json: { room: @room }
end