module Xeroizer::Record::AttachmentModel::Extensions

Public Instance Methods

attach_data(id, filename, data, content_type = "application/octet-stream", options = {}) click to toggle source
# File lib/xeroizer/models/attachment.rb, line 7
def attach_data(id, filename, data, content_type = "application/octet-stream", options = {})
  application.Attachment.attach_data(url, id, filename, data, content_type, options)
end
attach_file(id, filename, path, content_type = "application/octet-stream", options = {}) click to toggle source
# File lib/xeroizer/models/attachment.rb, line 11
def attach_file(id, filename, path, content_type = "application/octet-stream", options = {})
  application.Attachment.attach_file(url, id, filename, path, content_type, options)
end
attachments(id) click to toggle source
# File lib/xeroizer/models/attachment.rb, line 15
def attachments(id)
  application.Attachment.attachments_for(url, id)
end