Class: AutotaskRuby::Ticket

Inherits:
Object
  • Object
show all
Includes:
Entity, Query
Defined in:
lib/autotask_ruby/ticket.rb

Overview

Represents the Autotask Entity Ticket

Constant Summary collapse

FIELDS =
%i[id AccountID ContactID CreateDate Description DueDateTime LastActivityDate AssignedResourceID Status TicketNumber Title].freeze
                                                                                                                                    .each do |field|
  attr_accessor :"#{field.to_s.underscore}"
end

Constants included from Constants

Constants::AUTOTASK_TIME_FORMAT

Instance Method Summary collapse

Methods included from Query

#find, #query

Methods included from Entity

#build, #create, #field_set, #fields_to_xml, #format_field_to_xml, included, #initialize, #post_initialize, #to_bool, #to_date_time, #update

Methods included from Association

#belongs_to, #has_many, #has_one

Instance Method Details

#accountObject

Returns the associated Account



15
16
17
# File 'lib/autotask_ruby/ticket.rb', line 15

def 
  find('Account', )
end

#contactObject

Returns the associated Contact



20
21
22
# File 'lib/autotask_ruby/ticket.rb', line 20

def contact
  find('Contact', contact_id)
end