Class: ESP::Dashboard

Inherits:
Resource show all
Defined in:
lib/esp/resources/dashboard.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Dirty

#changed_attributes, #original_attributes, #original_attributes=

Methods included from LoadWithOriginalAttributes

#load

Class Method Details

.findvoid

This method returns an undefined value.

Not Implemented. You cannot search for a Dashboard.

Regular ARELlike methods are disabled.



8
9
10
# File 'lib/esp/resources/dashboard.rb', line 8

def self.find(*)
  fail ESP::NotImplementedError, 'Regular ARELlike methods are disabled.  Use the .recent method.'
end

.recentESP::Dashboard

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns with data from reports run in the last 2 hours

Returns:



41
42
43
44
# File 'lib/esp/resources/dashboard.rb', line 41

def self.recent
  # call find_every directly since find is overridden/not implemented
  where from: "#{prefix}dashboard/recent"
end

.where(attrs) ⇒ void

This method returns an undefined value.

Not Implemented. You cannot search for a Dashboard.

Regular ARELlike methods are disabled.



17
18
19
20
21
# File 'lib/esp/resources/dashboard.rb', line 17

def self.where(attrs)
  # when calling `recent.next_page` it will come into here
  return super if attrs[:from].to_s.include?('recent')
  fail ESP::NotImplementedError, 'Regular ARELlike methods are disabled.  Use the .recent method.'
end

Instance Method Details

#destroyvoid

This method returns an undefined value.

Not Implemented. You cannot destroy a Dashboard.



33
34
35
# File 'lib/esp/resources/dashboard.rb', line 33

def destroy
  fail ESP::NotImplementedError
end

#savevoid

This method returns an undefined value.

Not Implemented. You cannot create or update a Dashboard.



26
27
28
# File 'lib/esp/resources/dashboard.rb', line 26

def save
  fail ESP::NotImplementedError
end