Class: ZendeskAPI::Topic
- Inherits:
-
Resource
- Object
- Data
- DataResource
- Resource
- ZendeskAPI::Topic
- Defined in:
- lib/zendesk_api/resources/forum.rb
Defined Under Namespace
Classes: TopicComment, TopicVote
Instance Attribute Summary
Attributes inherited from Data
Instance Method Summary collapse
Methods included from Read
Methods included from Destroy
Methods included from Save
#save, #save!, #save_associations
Methods included from Verbs
Methods inherited from Data
#==, #id, #initialize, #method_missing, #new_record?, only_send_unnested_params, #path, resource_name, singular_resource_name, #to_s, unnested_params
Methods included from Associations
Constructor Details
This class inherits a constructor from ZendeskAPI::Data
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class ZendeskAPI::Data
Instance Method Details
#votes(opts = {}) ⇒ Object
44 45 46 47 48 49 |
# File 'lib/zendesk_api/resources/forum.rb', line 44 def votes(opts = {}) return @votes if @votes && !opts[:reload] association = ZendeskAPI::Association.new(:class => Topic::TopicVote, :parent => self, :path => 'votes') @votes = ZendeskAPI::Collection.new(@client, Topic::TopicVote, opts.merge(:association => association)) end |