Module: ProactiveSupport

Defined in:
lib/proactive_support.rb,
lib/proactive_support/engine.rb,
lib/proactive_support/version.rb,
lib/proactive_support/mgmt/flags.rb,
lib/proactive_support/mgmt/notes.rb,
app/models/proactive_support/flag.rb,
app/models/proactive_support/note.rb,
app/helpers/proactive_support/flags_helper.rb

Defined Under Namespace

Modules: FlagsHelper, Mgmt Classes: Configuration, Engine, Flag, Note

Constant Summary collapse

INFO =
0
WARNING =
1
ERROR =
2
VERSION =
"0.0.1"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configurationObject



33
34
35
36
37
# File 'lib/proactive_support.rb', line 33

def configuration
  @configuration ||= Configuration.new.tap do |c|
    c.transient_expiration = 1.day
  end
end

Class Method Details

.configure {|configuration| ... } ⇒ Object

Yields:



39
40
41
# File 'lib/proactive_support.rb', line 39

def configure
  yield(configuration)
end

.level_to_bootstrap(level) ⇒ Object



22
23
24
25
26
27
28
29
# File 'lib/proactive_support.rb', line 22

def level_to_bootstrap(level)
  case level
    when INFO then 'info'
    when WARNING then 'warning'
    when ERROR then 'danger'
    else ''
  end
end