Module: Spree::Admin::ImagesHelper

Defined in:
app/helpers/spree/admin/images_helper.rb

Instance Method Summary collapse

Instance Method Details

#options_text_for(image) ⇒ Object


4
5
6
7
8
9
10
11
12
13
14
# File 'app/helpers/spree/admin/images_helper.rb', line 4

def options_text_for(image)
  if image.viewable.is_a?(Spree::Variant)
    if image.viewable.is_master?
      Spree.t(:all)
    else
      image.viewable.options_text
    end
  else
    Spree.t(:all)
  end
end