class KayakoClient::TicketCustomFieldValue
Public Class Methods
new(*args)
click to toggle source
Calls superclass method
KayakoClient::Base::new
# File lib/kayako_client/ticket_custom_field.rb, line 29 def initialize(*args) super(*args) if defined?(@type) if @type == KayakoClient::CustomField::TYPE_FILE self.class.send(:include, KayakoClient::Attachment) if defined?(@contents) logger.debug "decoding base64 :contents" if logger @contents = Base64.decode64(@contents) @contents = Base64.decode64(@contents) end elsif @type == KayakoClient::CustomField::TYPE_DATE @contents = Time.parse(@contents) if defined?(@contents) end end end