Sha256: cafc733abfb2c8583cef9d93b0464d5f03a59268fbdae9e059a231e85379cff2
Contents?: true
Size: 438 Bytes
Versions: 6
Compression:
Stored size: 438 Bytes
Contents
class ViewAlbumsController < ApplicationController def index @albums = Album.page(params[:search], params[:page]) end def show if Album.find_by_filename(params[:filename]) == nil @album = Album.find(:first) render :file => "#{RAILS_ROOT}/public/404.html", :layout => false, :status => 404 else @album = Album.find_by_filename(params[:filename]) @photos = @album.photos.album_page(params[:page]) end end end
Version data entries
6 entries across 6 versions & 1 rubygems