Class: Stubhub::Event
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Document
demodulize, #fields, #initialize
Class Method Details
.find_by_event_id(event_id, options = {}) ⇒ Object
4
5
6
7
8
|
# File 'lib/stubhub/event.rb', line 4
def self.find_by_event_id(event_id, options = {})
params = {"stubhubDocumentType" => "#{demodulize(self).downcase}",
"event_id" => "#{event_id}"}
Client.make_request(Event, params, options)
end
|
.search(search_query, options = {}) ⇒ Object
10
11
12
13
14
15
|
# File 'lib/stubhub/event.rb', line 10
def self.search(search_query, options = {})
search_query = URI.escape(search_query)
params = {"stubhubDocumentType" => "#{demodulize(self).downcase}",
"description" => "#{search_query}"}
Client.make_request(Event, params, options)
end
|
Instance Method Details
#tickets(options = {}) ⇒ Object
17
18
19
20
21
|
# File 'lib/stubhub/event.rb', line 17
def tickets(options = {})
params = {"stubhubDocumentType" => "ticket",
"event_id" => "#{self.event_id}"}
Client.make_request(Ticket, params, options)
end
|