Using rails_representation_url to link to URL of image variant
This commit is contained in:
parent
6cda78d1ee
commit
ee4c96c428
4 changed files with 5 additions and 6 deletions
|
|
@ -19,7 +19,7 @@
|
||||||
- @pending_screenshots.each do |screenshot|
|
- @pending_screenshots.each do |screenshot|
|
||||||
.container.listview
|
.container.listview
|
||||||
/ = screenshot.status
|
/ = screenshot.status
|
||||||
a.black.fancybox href=screenshot.image.variant("800x600") rel='fancybox-thumb' title=screenshot.caption
|
a.black.fancybox href=rails_representation_url(screenshot.image.variant("800x600")) rel='fancybox-thumb' title=screenshot.caption
|
||||||
= image_tag(screenshot.image.variant("800x600"), alt: screenshot.caption)
|
= image_tag(screenshot.image.variant("800x600"), alt: screenshot.caption)
|
||||||
.imgcaption =screenshot.caption
|
.imgcaption =screenshot.caption
|
||||||
em.imgcaption =screenshot.adminstatus
|
em.imgcaption =screenshot.adminstatus
|
||||||
|
|
@ -43,7 +43,7 @@
|
||||||
- @package.screenshots.each do |screenshot|
|
- @package.screenshots.each do |screenshot|
|
||||||
- if screenshot.approved==true and screenshot.markedfordelete==false
|
- if screenshot.approved==true and screenshot.markedfordelete==false
|
||||||
.container.listview
|
.container.listview
|
||||||
a.black.fancybox href=screenshot.image.variant("800x600", timestamp: false) rel='fancybox-thumb' title=screenshot.caption
|
a.black.fancybox href=rails_representation_url(screenshot.image.variant("800x600", timestamp: false)) rel='fancybox-thumb' title=screenshot.caption
|
||||||
= image_tag(screenshot.image.variant("800x600"), alt: screenshot.caption)
|
= image_tag(screenshot.image.variant("800x600"), alt: screenshot.caption)
|
||||||
.imgcaption =screenshot.caption
|
.imgcaption =screenshot.caption
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@
|
||||||
- @current_users_screenshots.each do |screenshot|
|
- @current_users_screenshots.each do |screenshot|
|
||||||
.column
|
.column
|
||||||
|
|
||||||
a.black.fancybox href=screenshot.image.variant(resize: "800x600", timestamp: false)
|
a.black.fancybox href=rails_representation_url(screenshot.image.variant(resize: "800x600", timestamp: false))
|
||||||
div.grid-thumbnail
|
div.grid-thumbnail
|
||||||
= image_tag(screenshot.image.variant(resize: "160x120"), alt: screenshot.caption, class: 'thumbnail')
|
= image_tag(screenshot.image.variant(resize: "160x120"), alt: screenshot.caption, class: 'thumbnail')
|
||||||
div
|
div
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ h1 =@package.name
|
||||||
- screenshots_visible_to_user(@package).each do |screenshot|
|
- screenshots_visible_to_user(@package).each do |screenshot|
|
||||||
.listview
|
.listview
|
||||||
.text-center
|
.text-center
|
||||||
a.black.fancybox href=screenshot.image.variant(resize: "800x600") rel='fancybox-thumb' title=screenshot.caption
|
a.black.fancybox href=rails_representation_url(screenshot.image.variant(resize: "800x600")) rel='fancybox-thumb' title=screenshot.caption
|
||||||
= image_tag(screenshot.image.variant(resize: "800x600"), alt: screenshot.caption)
|
= image_tag(screenshot.image.variant(resize: "800x600"), alt: screenshot.caption)
|
||||||
- if screenshot.description
|
- if screenshot.description
|
||||||
.imgcaption =screenshot.description
|
.imgcaption =screenshot.description
|
||||||
|
|
|
||||||
|
|
@ -32,9 +32,8 @@ h1 = "Upload screenshots for #{@package.name}"
|
||||||
.small-up-1.medium-up-3.large-up-4.grid-thumbnails
|
.small-up-1.medium-up-3.large-up-4.grid-thumbnails
|
||||||
- @package.screenshots.all.each do |ss|
|
- @package.screenshots.all.each do |ss|
|
||||||
.column
|
.column
|
||||||
a.black.fancybox href=ss.image.variant(resize: "800x600") rel='fancybox-thumb' title=ss.caption
|
a.black.fancybox href=rails_representation_url(ss.image.variant(resize: "800x600")) rel='fancybox-thumb' title=ss.caption
|
||||||
= image_tag(ss.image.variant(resize: "160x120"), alt: ss.caption, class: 'thumbnail')
|
= image_tag(ss.image.variant(resize: "160x120"), alt: ss.caption, class: 'thumbnail')
|
||||||
|
|
||||||
// = render partial: 'packages/grid_thumbnail', locals: { pkg: pkg }
|
// = render partial: 'packages/grid_thumbnail', locals: { pkg: pkg }
|
||||||
|
|
||||||
//- else
|
//- else
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue