Sha256: 1ef1f08dd4bc967d2f5570cc1bea5c3a97922fe7fc8067665898d7ecf3957640

Contents?: true

Size: 831 Bytes

Versions: 2

Compression:

Stored size: 831 Bytes

Contents

#
# ishapi / galleries / _show
#

# @TODO: remove this file, this looks like a newsitem

json.id           gallery.id.to_s
json.item_type    gallery.class.name
json.name         gallery.name
json.galleryname  gallery.galleryname
json.description  gallery.description
json.username     gallery.username || 'piousbox'
json.n_photos     gallery.photos.length
json.slug         gallery.galleryname
json.subhead      gallery.subhead
json.partial!    'ishapi/application/meta', :item => gallery
if gallery.is_premium
  json.premium_tier gallery.premium_tier
  json.is_premium   gallery.premium_tier > 0
  json.is_purchased current_user&.profile&.has_premium_purchase( gallery )
  json.partial!    'ishapi/photos/index',     :photos => [ gallery.photos[0] ]
else
  json.partial!    'ishapi/photos/index',     :photos => gallery.photos
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ishapi-0.1.8.154 app/views/ishapi/galleries/_show.jbuilder
ishapi-0.1.8.153 app/views/ishapi/galleries/_show.jbuilder