Sha256: 0d732d5a3da585f8349a2908db8039100c3c8de752416469725a1097780daf49

Contents?: true

Size: 505 Bytes

Versions: 2

Compression:

Stored size: 505 Bytes

Contents

module Flexite
  module ApplicationHelper
    def present(*args, presenter)
      klass = "Flexite::#{presenter.to_s.camelize}Presenter".constantize
      yield(klass.new(self, *args))
    end

    def back_to_app
      link_to "Back to #{Flexite.config.app_name}", Flexite.config.app_link, class: 'btn btn-default'
    end

    def stage_select
      Rails.logger.debug { Flexite.config.stages }
      select_tag :stage, options_for_select(Flexite.config.stages), class: 'form-control'
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
flexite-0.0.13 app/helpers/flexite/application_helper.rb
flexite-0.0.12 app/helpers/flexite/application_helper.rb