Sha256: 3b0760b9e4772f73a49a04c61edf22183f1bb0b3f266124226f6305421dd6105

Contents?: true

Size: 553 Bytes

Versions: 7

Compression:

Stored size: 553 Bytes

Contents

##
# Outpost::Controller::Helpers
module Outpost
  module Controller
    module Helpers
      extend ActiveSupport::Concern

      # Public: Set the flash[:notice] message, only for HTML requests.
      #
      # message - (String) The message to add to the flash.
      #
      # Examples
      #
      #   notice("Success")
      #   flash[:notice]
      #   # => "Success"
      #
      # Returns nothing.
      def notice(message)
        flash[:notice] = message if request.format.html?
      end
    end # Helpers
  end # Controller
end # Outpost

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
outpost-cms-0.1.4 lib/outpost/controller/helpers.rb
outpost-cms-0.1.3 lib/outpost/controller/helpers.rb
outpost-cms-0.1.2 lib/outpost/controller/helpers.rb
outpost-cms-0.1.1 lib/outpost/controller/helpers.rb
outpost-cms-0.1.0 lib/outpost/controller/helpers.rb
outpost-cms-0.0.5 lib/outpost/controller/helpers.rb
outpost-cms-0.0.4 lib/outpost/controller/helpers.rb