Class: RuckusSpot::Location

Inherits:
Base
  • Object
show all
Defined in:
lib/ruckus-spot/location.rb

Class Method Summary collapse

Class Method Details

.by_date(date = Time.now.strftime('%Y-%m-%d'), limit = 50) ⇒ Object



10
11
12
# File 'lib/ruckus-spot/location.rb', line 10

def self.by_date(date = Time.now.strftime('%Y-%m-%d'), limit = 50)
  get(:by_date, date: date, limit: limit)
end

.collection_path(prefix_options = {}, query_options = nil) ⇒ Object



4
5
6
7
8
# File 'lib/ruckus-spot/location.rb', line 4

def self.collection_path(prefix_options = {}, query_options = nil)
  prefix_options, query_options = split_options(prefix_options) if query_options.nil?
  fail ActiveResource::MissingPrefixParam, 'venue_id prefix_option is missing' unless prefix_options.has_key?(:venue_id)
  "#{prefix(prefix_options)}#{collection_name}/last_known.json#{query_string(query_options)}"
end