Sha256: 7bef950b6d5c1032909050a4e837cb67cfefeff06155e3f2f1a83c1edbef53f8

Contents?: true

Size: 466 Bytes

Versions: 9

Compression:

Stored size: 466 Bytes

Contents

module E9Crm::OffersHelper
  def records_table_field_map_for_offer
    {
      :fields => { 
        :name => nil,
        :type => lambda {|r| r.class.model_name.human }
      }
    }
  end

  def offer_select_options(with_all_option = true)
    options = %w(contact file_download new_content_subscription newsletter_subscription video).map {|t| [t.titleize, t] }
    options.unshift(['All Types', nil]) if with_all_option
    options_for_select(options)
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
e9_crm-0.1.18 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.17 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.16 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.14 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.13 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.12 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.11 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.10 app/helpers/e9_crm/offers_helper.rb
e9_crm-0.1.8 app/helpers/e9_crm/offers_helper.rb