Sha256: 80cc7e56e18fcdc0476c3c9b026a8917fc682bbbcf06fdd7d0bf1a01f6904d37
Contents?: true
Size: 593 Bytes
Versions: 20
Compression:
Stored size: 593 Bytes
Contents
module C80Yax module Cats module CatViewHelper # выдать html строку с image_tag картинки категории def cat_image_tag(cat, thumb_type = 'thumb_md') res = '' if cat.image.present? res = image_tag cat.image.thumb_md end res.html_safe end # выдать урл картинки категории def cat_image_url(cat, thumb_type = 'thumb_md') res = '' if cat.image.present? res = cat.image.send(thumb_type) end res end end end end
Version data entries
20 entries across 20 versions & 1 rubygems