Class: PhotosController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- PhotosController
- Defined in:
- app/controllers/photos_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
3 4 5 |
# File 'app/controllers/photos_controller.rb', line 3 def index #@albums = Album.published.paginate(:page => params[:page], :per_page => 12) end |
#show ⇒ Object
7 8 9 10 |
# File 'app/controllers/photos_controller.rb', line 7 def show @album = Album.find(params[:album_id]) @photo = @album.photos.find(params[:id]) end |