find tag by title
This commit is contained in:
parent
7488cb9844
commit
1317435506
|
@ -4,7 +4,7 @@ class PhotosController < ApplicationController
|
|||
|
||||
def index
|
||||
if params[:tag_id]
|
||||
@photos = Tag.find( params[:tag_id] ).photos.find(:all, :order => "photos.id ASC")
|
||||
@photos = Tag.find_by_title( params[:tag_id] ).photos.find(:all, :order => "photos.id ASC")
|
||||
elsif params[:album_id]
|
||||
@photos = Album.find( params[:album_id]).photos.find(:all, :order => "photos.id ASC")
|
||||
elsif params[:q]
|
||||
|
|
Loading…
Reference in a new issue