Sha256: c8f0f6252b6b3d910b743e3d92f74bdc48e2cb67fe47e6278f5e8c582d51faec

Contents?: true

Size: 369 Bytes

Versions: 7

Compression:

Stored size: 369 Bytes

Contents

module ApplicationHelper
  def flash_class(level)
    case level.to_sym
        when :notice then "alert-info"
        when :success then "alert-success"
        when :alert then "alert-warning"
        when :error then "alert-danger"
        else "alert-danger"
    end
  end

  def page_title
    @title || controller_name.gsub( /Controller/, "" ).humanize
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
happy_seed-0.0.18 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.17 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.16 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.15 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.14 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.13 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb
happy_seed-0.0.12 lib/generators/happy_seed/bootstrap/templates/app/helpers/application_helper.rb