Fix gallery front end when display all categories
This commit is contained in:
parent
9ea8b536b5
commit
827a5e52e7
|
@ -1,7 +1,11 @@
|
|||
class Panel::Gallery::FrontEnd::AlbumsController < OrbitWidgetController
|
||||
def index
|
||||
if params[:category_id].blank?
|
||||
@albums = GalleryAlbum.where()
|
||||
else
|
||||
@albums = GalleryAlbum.where(:category_id.in => params[:category_id])
|
||||
end
|
||||
end
|
||||
|
||||
def show
|
||||
@album = GalleryAlbum.find(params[:id])
|
||||
|
|
Loading…
Reference in New Issue