Module: Mercy::ClassMethods

Defined in:
lib/mercy/class_methods.rb

Instance Method Summary collapse

Instance Method Details

#status_builderObject



13
14
15
# File 'lib/mercy/class_methods.rb', line 13

def status_builder
  @status_builder ||= Mercy::StatusBuilder.new
end

#status_report(*attr_names) ⇒ Object



4
5
6
7
8
9
10
11
# File 'lib/mercy/class_methods.rb', line 4

def status_report(*attr_names)
  id = attr_names.first
  options = {
    id: id
  }.merge(attr_names.extract_options!)

  self.status_builder.add_report_config(id, options)
end