Sha256: f8b6f9e4f297e3ec4f8c5a46f072e3f76de29582dadf1bc0f554aef0d8c78e9f
Contents?: true
Size: 597 Bytes
Versions: 7
Compression:
Stored size: 597 Bytes
Contents
module ActiveScaffold module Helpers module ListColumnHelpers def active_scaffold_column_dragonfly(column, record) attachment = record.send("#{column.name}") return nil unless attachment.present? content = if attachment.image? image_tag(attachment.thumb(column.options[:thumb] || ActiveScaffold::Bridges::Dragonfly::Lib::DragonflyBridgeHelpers.thumbnail_style).url, :border => 0) else attachment.name end link_to(content, attachment.remote_url, {'data-popup' => true, :target => '_blank'}) end end end end
Version data entries
7 entries across 7 versions & 2 rubygems