new theater for gallery..
This commit is contained in:
1 parent
863d89e46b
commit
f211afc523
7 files changed
+1153
-12
No files matched your search
@@ -27,7 +27,7 @@ class GalleriesController < ApplicationController
|
||||
{
|
||||
"image-description" => a.description,
|
||||
"alt_title" => alt_text,
|
||||
"link_to_show" => "/" + I18n.locale.to_s + params[:url] + "/-" + a.id.to_s + "?method=theater",
|
||||
"link_to_show" => "/xhr/galleries/theater/" + a.id.to_s,
|
||||
"thumb-src" => a.file.thumb.url
|
||||
}
|
||||
end
|
||||
@@ -64,7 +64,7 @@ class GalleriesController < ApplicationController
|
||||
alt_text = (a.description.nil? || a.description == "" ? "gallery image" : a.description)
|
||||
|
||||
{
|
||||
"link_to_show" => OrbitHelper.widget_more_url + "/-" + a.id.to_s + "?method=theater",
|
||||
"link_to_show" => OrbitHelper.widget_more_url + "/" + a.album.to_param + "#" + a.id.to_s,
|
||||
"alt_title" => alt_text,
|
||||
"thumb-src" => a.file.thumb.url
|
||||
}
|
||||
@@ -94,17 +94,17 @@ class GalleriesController < ApplicationController
|
||||
end
|
||||
|
||||
def theater
|
||||
params = OrbitHelper.params
|
||||
image = AlbumImage.find(params[:uid])
|
||||
image = AlbumImage.find(params[:id])
|
||||
albumid = image.album_id
|
||||
album = Album.find(albumid)
|
||||
images = album.album_images.asc(:order)
|
||||
{
|
||||
"album" => album,
|
||||
"images" => images,
|
||||
"image" => image,
|
||||
"wall_images" => imgs(albumid),
|
||||
"back_to_albums" => OrbitHelper.url_to_show(album.to_param)
|
||||
}
|
||||
data = {
|
||||
"album" => album,
|
||||
# "images" => images,
|
||||
"image" => image.id.to_s,
|
||||
"images" => imgs(albumid)
|
||||
}
|
||||
|
||||
render :json => {"data" => data}.to_json
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user