quickbooks-ruby 0.1.9 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/lib/quickbooks/model/account.rb +1 -1
  3. data/lib/quickbooks/model/attachable.rb +33 -0
  4. data/lib/quickbooks/model/attachable_ref.rb +22 -0
  5. data/lib/quickbooks/model/bill.rb +1 -1
  6. data/lib/quickbooks/model/bill_line_item.rb +1 -1
  7. data/lib/quickbooks/model/bill_payment.rb +1 -1
  8. data/lib/quickbooks/model/bill_payment_line_item.rb +1 -1
  9. data/lib/quickbooks/model/class.rb +1 -1
  10. data/lib/quickbooks/model/company_info.rb +1 -1
  11. data/lib/quickbooks/model/credit_memo.rb +1 -1
  12. data/lib/quickbooks/model/customer.rb +1 -1
  13. data/lib/quickbooks/model/customer_change.rb +1 -1
  14. data/lib/quickbooks/model/delivery_info.rb +8 -0
  15. data/lib/quickbooks/model/department.rb +1 -1
  16. data/lib/quickbooks/model/deposit.rb +44 -0
  17. data/lib/quickbooks/model/deposit_line_detail.rb +17 -0
  18. data/lib/quickbooks/model/deposit_line_item.rb +35 -0
  19. data/lib/quickbooks/model/employee.rb +1 -1
  20. data/lib/quickbooks/model/entity_ref.rb +8 -0
  21. data/lib/quickbooks/model/estimate.rb +1 -1
  22. data/lib/quickbooks/model/invoice.rb +3 -1
  23. data/lib/quickbooks/model/invoice_change.rb +1 -1
  24. data/lib/quickbooks/model/invoice_line_item.rb +1 -1
  25. data/lib/quickbooks/model/item.rb +1 -1
  26. data/lib/quickbooks/model/item_change.rb +1 -1
  27. data/lib/quickbooks/model/journal_entry.rb +1 -1
  28. data/lib/quickbooks/model/line.rb +1 -1
  29. data/lib/quickbooks/model/payment.rb +1 -1
  30. data/lib/quickbooks/model/payment_method.rb +1 -1
  31. data/lib/quickbooks/model/physical_address.rb +1 -1
  32. data/lib/quickbooks/model/purchase.rb +1 -1
  33. data/lib/quickbooks/model/purchase_line_item.rb +1 -1
  34. data/lib/quickbooks/model/purchase_order.rb +1 -1
  35. data/lib/quickbooks/model/refund_receipt.rb +1 -1
  36. data/lib/quickbooks/model/sales_receipt.rb +1 -1
  37. data/lib/quickbooks/model/tax_line.rb +2 -2
  38. data/lib/quickbooks/model/tax_rate.rb +1 -1
  39. data/lib/quickbooks/model/term.rb +1 -1
  40. data/lib/quickbooks/model/time_activity.rb +1 -1
  41. data/lib/quickbooks/model/upload.rb +35 -0
  42. data/lib/quickbooks/model/vendor.rb +1 -1
  43. data/lib/quickbooks/model/vendor_change.rb +1 -1
  44. data/lib/quickbooks/model/vendor_credit.rb +1 -1
  45. data/lib/quickbooks/service/attachable.rb +12 -0
  46. data/lib/quickbooks/service/base_service.rb +22 -24
  47. data/lib/quickbooks/service/deposit.rb +16 -0
  48. data/lib/quickbooks/service/invoice.rb +12 -1
  49. data/lib/quickbooks/service/upload.rb +35 -0
  50. data/lib/quickbooks/util/multipart.rb +76 -0
  51. data/lib/quickbooks/version.rb +1 -1
  52. data/lib/quickbooks-ruby.rb +12 -0
  53. metadata +46 -20
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ce384cefff5b0aba72b01e162823f74c4ccaf99b
4
- data.tar.gz: bd2a48112be5e3f3155589beacf62c385a81d8d0
3
+ metadata.gz: ca953110f19adc2d6eaac99ad1d2b78e3afee201
4
+ data.tar.gz: aab52b8a7cb8074d1525c51620328d18690d55fb
5
5
  SHA512:
6
- metadata.gz: 09ddf73d07a87ce71b12ffcdbfe8726bcc7b98ac0c7ab96aef75e6ed22cbf7e66ec8a3085ef3de674fe6a21e02ade29e7bdf112eb5b5541e92a2fcac2f6ad8f0
7
- data.tar.gz: 05a8b2f6c4a78628ec5d874937a71db087c39b19096aaf21b754205f5336c9c5ab48c7472406133ce72195bd337b044fc550ce666367c4d71edb4cb7bee351f4
6
+ metadata.gz: 82b7cca62afb14e5f94b6d7e8c2b223ef6012cc817b01626528845caf2584c1ea045e5218c115e123357f0f6eecadc1055621f83305f0545cba7f1c27e7e843e
7
+ data.tar.gz: 2b8b39f095192c215fab751ae1ccc23dba5faae48c1963d92d7bb52c3bec4efb74a6e2f2ccab626c8e29f9285a47eddc7b3e0e5b71be5999ef248b6e08071185
@@ -15,7 +15,7 @@ module Quickbooks
15
15
 
16
16
  xml_name XML_NODE
17
17
 
18
- xml_accessor :id, :from => 'Id', :as => Integer
18
+ xml_accessor :id, :from => 'Id'
19
19
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
20
20
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
21
21
  xml_accessor :has_attachment?, :from => 'HasAttachment'
@@ -0,0 +1,33 @@
1
+ require 'quickbooks/model/attachable_ref'
2
+
3
+ module Quickbooks
4
+ module Model
5
+ class Attachable < BaseModel
6
+
7
+ XML_COLLECTION_NODE = "Attachable"
8
+ XML_NODE = "Attachable"
9
+ REST_RESOURCE = 'attachable'
10
+
11
+ xml_accessor :id, :from => 'Id'
12
+ xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
+ xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
+ xml_accessor :attachable_ref, :as => AttachableRef
15
+ xml_accessor :file_name
16
+ xml_accessor :file_access_uri
17
+ xml_accessor :temp_download_uri
18
+ xml_accessor :size
19
+ xml_accessor :content_type
20
+ xml_accessor :category
21
+ xml_accessor :lat
22
+ xml_accessor :long
23
+ xml_accessor :place_name
24
+ xml_accessor :note
25
+ xml_accessor :tag
26
+ xml_accessor :thumbnail_file_access_uri
27
+ xml_accessor :thumbnail_temp_download_uri
28
+
29
+ reference_setters :attachable_ref
30
+
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,22 @@
1
+ require 'quickbooks/model/entity_ref'
2
+ require 'quickbooks/model/custom_field'
3
+
4
+ module Quickbooks
5
+ module Model
6
+ class AttachableRef < BaseModel
7
+ xml_accessor :entity_ref, :as => EntityRef
8
+ xml_accessor :line_info
9
+ xml_accessor :include_on_send?
10
+ xml_accessor :inactive?
11
+ xml_accessor :no_ref_only?
12
+ xml_accessor :custom_fields, :as => [CustomField]
13
+
14
+ def initialize(an_entity_ref = nil)
15
+ if an_entity_ref
16
+ self.entity_ref = an_entity_ref
17
+ end
18
+ end
19
+
20
+ end
21
+ end
22
+ end
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  XML_NODE = "Bill"
9
9
  REST_RESOURCE = 'bill'
10
10
 
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
13
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
14
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -6,7 +6,7 @@ module Quickbooks
6
6
  ACCOUNT_BASED_EXPENSE_LINE_DETAIL = 'AccountBasedExpenseLineDetail'
7
7
  ITEM_BASED_EXPENSE_LINE_DETAIL = 'ItemBasedExpenseLineDetail'
8
8
 
9
- xml_accessor :id, :from => 'Id', :as => Integer
9
+ xml_accessor :id, :from => 'Id'
10
10
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
11
11
  xml_accessor :description, :from => 'Description'
12
12
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => to_xml_big_decimal
@@ -5,7 +5,7 @@ module Quickbooks
5
5
  XML_NODE = "BillPayment"
6
6
  REST_RESOURCE = 'billpayment'
7
7
 
8
- xml_accessor :id, :from => 'Id', :as => Integer
8
+ xml_accessor :id, :from => 'Id'
9
9
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
10
10
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
11
11
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -6,7 +6,7 @@ module Quickbooks
6
6
  PAYMENT_LINE_DETAIL = 'PaymentLineDetail'
7
7
  DISCOUNT_LINE_DETAIL = 'DiscountLineDetail'
8
8
 
9
- xml_accessor :id, :from => 'Id', :as => Integer
9
+ xml_accessor :id, :from => 'Id'
10
10
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
11
11
  xml_accessor :description, :from => 'Description'
12
12
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => to_xml_big_decimal
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  include NameEntity::PermitAlterations
9
9
 
10
10
  xml_name XML_NODE
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
13
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
14
  xml_accessor :name, :from => 'Name'
@@ -6,7 +6,7 @@ module Quickbooks
6
6
  REST_RESOURCE = 'companyinfo'
7
7
 
8
8
  xml_name XML_NODE
9
- xml_accessor :id, :from => 'Id', :as => Integer
9
+ xml_accessor :id, :from => 'Id'
10
10
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
11
11
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
12
12
  xml_accessor :company_name, :from => 'CompanyName'
@@ -9,7 +9,7 @@ module Quickbooks
9
9
  XML_NODE = "CreditMemo"
10
10
  REST_RESOURCE = 'creditmemo'
11
11
 
12
- xml_accessor :id, :from => 'Id', :as => Integer
12
+ xml_accessor :id, :from => 'Id'
13
13
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
14
14
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
15
15
  xml_accessor :auto_doc_number, :from => 'AutoDocNumber' # See auto_doc_number! method below for usage
@@ -17,7 +17,7 @@ module Quickbooks
17
17
  include NameEntity::PermitAlterations
18
18
 
19
19
  xml_name XML_NODE
20
- xml_accessor :id, :from => 'Id', :as => Integer
20
+ xml_accessor :id, :from => 'Id'
21
21
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
22
22
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
23
23
  xml_accessor :title, :from => 'Title'
@@ -4,7 +4,7 @@ module Quickbooks
4
4
  class CustomerChange < BaseModel
5
5
  XML_NODE = "Customer"
6
6
 
7
- xml_accessor :id, :from => 'Id', :as => Integer
7
+ xml_accessor :id, :from => 'Id'
8
8
  xml_accessor :status, :from => '@status'
9
9
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
10
10
  end
@@ -0,0 +1,8 @@
1
+ module Quickbooks
2
+ module Model
3
+ class DeliveryInfo < BaseModel
4
+ xml_accessor :delivery_type, :from => 'DeliveryType'
5
+ xml_accessor :delivery_time, :from => 'DeliveryTime', :as => DateTime
6
+ end
7
+ end
8
+ end
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  include NameEntity::PermitAlterations
9
9
 
10
10
  xml_name XML_NODE
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
13
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
14
  xml_accessor :name, :from => 'Name'
@@ -0,0 +1,44 @@
1
+ # == Business Rules
2
+ # * There must be at least one line item included in a create request
3
+ # * Any transaction that funds the Undeposited Funds account can be linked to a Deposit object with Deposit.Line.LinkedTxn
4
+
5
+ module Quickbooks
6
+ module Model
7
+ class Deposit < BaseModel
8
+ include DocumentNumbering
9
+ include HasLineItems
10
+
11
+ #== Constants
12
+ XML_COLLECTION_MODE = "Deposit"
13
+ XML_NODE = "Deposit"
14
+ REST_RESOURCE = "deposit"
15
+
16
+ xml_accessor :id, :from => "Id", :as => Integer
17
+ xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
18
+ xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
19
+ xml_accessor :custom_fields, :from => 'CustomField', :as => [CustomField]
20
+ xml_accessor :auto_doc_number, :from => 'AutoDocNumber' # See auto_doc_number! method below for usage
21
+ xml_accessor :doc_number, :from => 'DocNumber'
22
+ xml_accessor :txn_date, :from => 'TxnDate', :as => Date
23
+ xml_accessor :department_ref, :from => 'DepartmentRef', :as => BaseReference
24
+ xml_accessor :currency_ref, :from => 'CurrencyRef', :as => BaseReference
25
+ xml_accessor :exchange_rate, :from => 'ExchangeRate', :as => BigDecimal, :to_xml => to_xml_big_decimal
26
+ xml_accessor :private_note, :from => 'PrivateNote'
27
+ xml_accessor :txn_status, :from => 'TxnStatus'
28
+ xml_accessor :line_items, :from => 'Line', :as => [DepositLineItem]
29
+ xml_accessor :txn_tax_detail, :from => 'TxnTaxDetail', :as => TransactionTaxDetail
30
+ xml_accessor :deposit_to_account_ref, :from => 'DepositToAccountRef', :as => BaseReference
31
+ xml_accessor :total, :from => 'TotalAmt', :as => BigDecimal, :to_xml => to_xml_big_decimal
32
+
33
+
34
+ reference_setters :department_ref, :currency_ref, :deposit_to_account_ref
35
+
36
+ #== Validations
37
+ validate :line_item_size
38
+ validate :document_numbering
39
+
40
+ private
41
+
42
+ end
43
+ end
44
+ end
@@ -0,0 +1,17 @@
1
+ module Quickbooks
2
+ module Model
3
+ class DepositLineDetail < BaseModel
4
+
5
+ xml_accessor :entity, :from => 'Entity', :as => Entity
6
+ xml_accessor :class_ref, :from => 'ClassRef', :as => BaseReference
7
+ xml_accessor :account_ref, :from => 'AccountRef', :as => BaseReference
8
+ xml_accessor :payment_method_ref, :from => 'PaymentMethodRef', :as => BaseReference
9
+ xml_accessor :check_num, :from => 'CheckNum'
10
+ xml_accessor :txn_type, :from => 'TxnType'
11
+ xml_accessor :custom_fields, :from => 'CustomField', :as => [CustomField]
12
+
13
+ reference_setters :class_ref, :account_ref, :payment_method_ref
14
+
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,35 @@
1
+ module Quickbooks
2
+ module Model
3
+ class DepositLineItem < BaseModel
4
+
5
+ #== Constants
6
+ DEPOSIT_LINE_DETAIL = 'DepositLineDetail'
7
+
8
+ xml_accessor :id, :from => 'Id'
9
+ xml_accessor :line_num, :from => 'LineNum', :as => Integer
10
+ xml_accessor :description, :from => 'Description'
11
+ xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => to_xml_big_decimal
12
+ xml_accessor :linked_transactions, :from => 'LinkedTxn', :as => [LinkedTransaction]
13
+
14
+ xml_accessor :detail_type, :from => 'DetailType'
15
+
16
+ #== Various detail types
17
+ xml_accessor :deposit_line_detail, :from => 'DepositLineDetail', :as => DepositLineDetail
18
+
19
+ xml_accessor :custom_fields, :from => 'CustomField', :as => [CustomField]
20
+
21
+
22
+ def deposit_line_detail?
23
+ detail_type.to_s == DEPOSIT_LINE_DETAIL
24
+ end
25
+
26
+ def deposit_line_detail!
27
+ self.detail_type = DEPOSIT_LINE_DETAIL
28
+ self.deposit_line_detail = DepositLineDetail.new
29
+
30
+ yield self.deposit_line_detail if block_given?
31
+ end
32
+
33
+ end
34
+ end
35
+ end
@@ -12,7 +12,7 @@ module Quickbooks
12
12
  include NameEntity::PermitAlterations
13
13
 
14
14
  xml_name XML_NODE
15
- xml_accessor :id, :from => 'Id', :as => Integer
15
+ xml_accessor :id, :from => 'Id'
16
16
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
17
17
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
18
18
  xml_accessor :organization?, :from => 'Organization'
@@ -0,0 +1,8 @@
1
+ module Quickbooks
2
+ module Model
3
+ class EntityRef < BaseModel
4
+ xml_accessor :type
5
+ xml_accessor :value
6
+ end
7
+ end
8
+ end
@@ -16,7 +16,7 @@ module Quickbooks
16
16
  XML_COLLECTION_NODE = "Estimate"
17
17
  XML_NODE = "Estimate"
18
18
 
19
- xml_accessor :id, :from => 'Id', :as => Integer
19
+ xml_accessor :id, :from => 'Id'
20
20
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
21
21
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
22
22
  xml_accessor :custom_fields, :from => 'CustomField', :as => [CustomField]
@@ -18,7 +18,7 @@ module Quickbooks
18
18
  XML_NODE = "Invoice"
19
19
  EMAIL_STATUS_NEED_TO_SEND = 'NeedToSend'
20
20
 
21
- xml_accessor :id, :from => 'Id', :as => Integer
21
+ xml_accessor :id, :from => 'Id'
22
22
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
23
23
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
24
24
  xml_accessor :custom_fields, :from => 'CustomField', :as => [CustomField]
@@ -51,12 +51,14 @@ module Quickbooks
51
51
  xml_accessor :deposit, :from => 'Deposit', :as => BigDecimal, :to_xml => to_xml_big_decimal
52
52
  xml_accessor :department_ref, :from => 'DepartmentRef', :as => BaseReference
53
53
  xml_accessor :allow_ipn_payment?, :from => 'AllowIPNPayment'
54
+ xml_accessor :delivery_info, :from => 'DeliveryInfo', :as => DeliveryInfo
54
55
  xml_accessor :bill_email, :from => 'BillEmail', :as => EmailAddress
55
56
  xml_accessor :allow_online_payment?, :from => 'AllowOnlinePayment'
56
57
  xml_accessor :allow_online_credit_card_payment?, :from => 'AllowOnlineCreditCardPayment'
57
58
  xml_accessor :allow_online_ach_payment?, :from => 'AllowOnlineACHPayment'
58
59
  xml_accessor :deposit_to_account_ref, :from => 'DepositToAccountRef', :as => BaseReference
59
60
 
61
+
60
62
  reference_setters
61
63
 
62
64
  #== This adds aliases for backwards compatability to old attributes names
@@ -4,7 +4,7 @@ module Quickbooks
4
4
  class InvoiceChange < BaseModel
5
5
  XML_NODE = "Invoice"
6
6
 
7
- xml_accessor :id, :from => 'Id', :as => Integer
7
+ xml_accessor :id, :from => 'Id'
8
8
  xml_accessor :status, :from => '@status'
9
9
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
10
10
  end
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  PAYMENT_LINE_DETAIL = 'PaymentLineDetail'
9
9
  DISCOUNT_LINE_DETAIL = 'DiscountLineDetail'
10
10
 
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
13
13
  xml_accessor :description, :from => 'Description'
14
14
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => to_xml_big_decimal
@@ -17,7 +17,7 @@ module Quickbooks
17
17
  ITEM_TYPES = [INVENTORY_TYPE, NON_INVENTORY_TYPE, SERVICE_TYPE]
18
18
 
19
19
  xml_name 'Item'
20
- xml_accessor :id, :from => 'Id', :as => Integer
20
+ xml_accessor :id, :from => 'Id'
21
21
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
22
22
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
23
23
  xml_accessor :name, :from => 'Name'
@@ -4,7 +4,7 @@ module Quickbooks
4
4
  class ItemChange < BaseModel
5
5
  XML_NODE = "Item"
6
6
 
7
- xml_accessor :id, :from => 'Id', :as => Integer
7
+ xml_accessor :id, :from => 'Id'
8
8
  xml_accessor :status, :from => '@status'
9
9
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
10
10
  end
@@ -7,7 +7,7 @@ module Quickbooks
7
7
  XML_NODE = "JournalEntry"
8
8
  REST_RESOURCE = 'journalentry'
9
9
 
10
- xml_accessor :id, :from => 'Id', :as => Integer
10
+ xml_accessor :id, :from => 'Id'
11
11
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
12
12
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
13
13
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  DISCOUNT_LINE_DETAIL = 'DiscountLineDetail'
9
9
  JOURNAL_ENTRY_LINE_DETAIL = 'JournalEntryLineDetail'
10
10
 
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
13
13
  xml_accessor :description, :from => 'Description'
14
14
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => to_xml_big_decimal
@@ -7,7 +7,7 @@ module Quickbooks
7
7
  XML_NODE = "Payment"
8
8
  REST_RESOURCE = 'payment'
9
9
 
10
- xml_accessor :id, :from => 'Id', :as => Integer
10
+ xml_accessor :id, :from => 'Id'
11
11
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
12
12
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
13
13
  xml_accessor :txn_date, :from => 'TxnDate', :as => Date
@@ -11,7 +11,7 @@ module Quickbooks
11
11
 
12
12
  PAYMENT_METHOD_TYPES = [CREDIT_CARD, NON_CREDIT_CARD]
13
13
 
14
- xml_accessor :id, :from => 'Id', :as => Integer
14
+ xml_accessor :id, :from => 'Id'
15
15
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
16
16
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
17
17
  xml_accessor :name, :from => 'Name'
@@ -1,7 +1,7 @@
1
1
  module Quickbooks
2
2
  module Model
3
3
  class PhysicalAddress < BaseModel
4
- xml_accessor :id, :from => 'Id', :as => Integer
4
+ xml_accessor :id, :from => 'Id'
5
5
  xml_accessor :line1, :from => 'Line1'
6
6
  xml_accessor :line2, :from => 'Line2'
7
7
  xml_accessor :line3, :from => 'Line3'
@@ -19,7 +19,7 @@ module Quickbooks
19
19
  XML_COLLECTION_NODE = "Purchase"
20
20
  XML_NODE = "Purchase"
21
21
 
22
- xml_accessor :id, :from => 'Id', :as => Integer
22
+ xml_accessor :id, :from => 'Id'
23
23
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
24
24
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
25
25
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -7,7 +7,7 @@ module Quickbooks
7
7
  ACCOUNT_BASED_EXPENSE_LINE_DETAIL = 'AccountBasedExpenseLineDetail'
8
8
  GROUP_LINE_DETAIL = 'GroupLineDetail'
9
9
 
10
- xml_accessor :id, :from => 'Id', :as => Integer
10
+ xml_accessor :id, :from => 'Id'
11
11
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
12
12
  xml_accessor :description, :from => 'Description'
13
13
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => Proc.new { |val| val.to_f }
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  XML_COLLECTION_NODE = "PurchaseOrder"
9
9
  XML_NODE = "PurchaseOrder"
10
10
 
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
13
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
14
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -8,7 +8,7 @@ module Quickbooks
8
8
  XML_NODE = "RefundReceipt"
9
9
  REST_RESOURCE = 'refundreceipt'
10
10
 
11
- xml_accessor :id, :from => 'Id', :as => Integer
11
+ xml_accessor :id, :from => 'Id'
12
12
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
13
13
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
14
14
  xml_accessor :auto_doc_number, :from => 'AutoDocNumber' # See auto_doc_number! method below for usage
@@ -9,7 +9,7 @@ module Quickbooks
9
9
  XML_NODE = "SalesReceipt"
10
10
  REST_RESOURCE = 'salesreceipt'
11
11
 
12
- xml_accessor :id, :from => 'Id', :as => Integer
12
+ xml_accessor :id, :from => 'Id'
13
13
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
14
14
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
15
15
  xml_accessor :auto_doc_number, :from => 'AutoDocNumber' # See auto_doc_number! method below for usage
@@ -2,12 +2,12 @@ module Quickbooks
2
2
  module Model
3
3
  class TaxLine < BaseModel
4
4
 
5
- xml_accessor :id, :from => 'Id', :as => Integer
5
+ xml_accessor :id, :from => 'Id'
6
6
  xml_accessor :line_num, :from => 'LineNum', :as => Integer
7
7
  xml_accessor :description, :from => 'Description'
8
8
  xml_accessor :amount, :from => 'Amount', :as => BigDecimal, :to_xml => Proc.new { |val| val.to_f }
9
9
  xml_accessor :detail_type, :from => 'DetailType'
10
-
10
+
11
11
  xml_accessor :tax_line_detail, :from => 'TaxLineDetail', :as => TaxLineDetail
12
12
 
13
13
  end
@@ -5,7 +5,7 @@ module Quickbooks
5
5
  XML_NODE = "TaxRate"
6
6
  REST_RESOURCE = "taxrate"
7
7
 
8
- xml_accessor :id, :from => "Id", :as => Integer
8
+ xml_accessor :id, :from => "Id"
9
9
  xml_accessor :sync_token, :from => "SyncToken", :as => Integer
10
10
  xml_accessor :meta_data, :from => "MetaData", :as => MetaData
11
11
  xml_accessor :name, :from => "Name"
@@ -5,7 +5,7 @@ module Quickbooks
5
5
  XML_NODE = "Term"
6
6
  REST_RESOURCE = 'term'
7
7
 
8
- xml_accessor :id, :from => 'Id', :as => Integer
8
+ xml_accessor :id, :from => 'Id'
9
9
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
10
10
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
11
11
  xml_accessor :name, :from => 'Name'
@@ -9,7 +9,7 @@ module Quickbooks
9
9
 
10
10
  xml_name XML_NODE
11
11
 
12
- xml_accessor :id, :from => 'Id', :as => Integer
12
+ xml_accessor :id, :from => 'Id'
13
13
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
14
14
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
15
15
 
@@ -0,0 +1,35 @@
1
+ module Quickbooks
2
+ module Model
3
+ class Upload < BaseModel
4
+ xml_convention :camelcase
5
+
6
+ #xml_accessor :attache, :as => Attachable
7
+
8
+ end
9
+ end
10
+ end
11
+
12
+ =begin
13
+
14
+ Response XML:
15
+
16
+ <IntuitResponse xmlns="http://schema.intuit.com/finance/v3" time="2014-08-18T09:58:04.583-07:00">
17
+ <AttachableResponse>
18
+ <Attachable domain="QBO" sparse="false">
19
+ <Id>2700000000001439108</Id>
20
+ <SyncToken>0</SyncToken>
21
+ <MetaData>
22
+ <CreateTime>2014-08-18T09:58:06-07:00</CreateTime>
23
+ <LastUpdatedTime>2014-08-18T09:58:06-07:00</LastUpdatedTime>
24
+ </MetaData>
25
+ <FileName>monkey.jpg</FileName>
26
+ <FileAccessUri>/v3/company/1002341430/download/2700000000001439108</FileAccessUri>
27
+ <TempDownloadUri>https://intuit-qbo-prod-30.s3.amazonaws.com/1002341430%2Fattachments%2Fmonkey.jpg?Expires=1408381986&amp;AWSAccessKeyId=AKIAJEXDXKNYCBUNCCCQ&amp;Signature=WOVACYm6zi1rM5EGZRq3d3AMSM0%3D</TempDownloadUri>
28
+ <Size>105840</Size>
29
+ <ContentType>image/jpeg</ContentType>
30
+ <ThumbnailFileAccessUri>/v3/company/1002341430/attachable-thumbnail/2700000000001439108</ThumbnailFileAccessUri>
31
+ </Attachable>
32
+ </AttachableResponse>
33
+ </IntuitResponse>
34
+
35
+ =end
@@ -14,7 +14,7 @@ module Quickbooks
14
14
  include NameEntity::PermitAlterations
15
15
 
16
16
  xml_name XML_NODE
17
- xml_accessor :id, :from => 'Id', :as => Integer
17
+ xml_accessor :id, :from => 'Id'
18
18
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
19
19
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
20
20
  xml_accessor :attachable_ref, :from => 'AttachableRef', :as => BaseReference
@@ -4,7 +4,7 @@ module Quickbooks
4
4
  class VendorChange < BaseModel
5
5
  XML_NODE = "Vendor"
6
6
 
7
- xml_accessor :id, :from => 'Id', :as => Integer
7
+ xml_accessor :id, :from => 'Id'
8
8
  xml_accessor :status, :from => '@status'
9
9
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
10
10
  end
@@ -12,7 +12,7 @@ module Quickbooks
12
12
  XML_COLLECTION_NODE = "VendorCredit"
13
13
  XML_NODE = "VendorCredit"
14
14
 
15
- xml_accessor :id, :from => 'Id', :as => Integer
15
+ xml_accessor :id, :from => 'Id'
16
16
  xml_accessor :sync_token, :from => 'SyncToken', :as => Integer
17
17
  xml_accessor :meta_data, :from => 'MetaData', :as => MetaData
18
18
  xml_accessor :doc_number, :from => 'DocNumber'
@@ -0,0 +1,12 @@
1
+ module Quickbooks
2
+ module Service
3
+ class Attachable < BaseService
4
+
5
+ private
6
+
7
+ def model
8
+ Quickbooks::Model::Attachable
9
+ end
10
+ end
11
+ end
12
+ end
@@ -142,9 +142,10 @@ module Quickbooks
142
142
  # ...
143
143
  # </Customer>
144
144
  # </IntuitResponse>
145
- def parse_singular_entity_response(model, xml)
145
+ def parse_singular_entity_response(model, xml, node_xpath_prefix = nil)
146
146
  xmldoc = Nokogiri(xml)
147
- xmldoc.xpath("//xmlns:IntuitResponse/xmlns:#{model::XML_NODE}")[0]
147
+ prefix = node_xpath_prefix || model::XML_NODE
148
+ xmldoc.xpath("//xmlns:IntuitResponse/xmlns:#{prefix}")[0]
148
149
  end
149
150
 
150
151
  # A successful delete request returns a XML packet like:
@@ -158,28 +159,6 @@ module Quickbooks
158
159
  xmldoc.xpath("//xmlns:IntuitResponse/xmlns:#{model::XML_NODE}[@status='Deleted']").length == 1
159
160
  end
160
161
 
161
- def perform_write(model, body = "", params = {}, headers = {})
162
- url = url_for_resource(model::REST_RESOURCE)
163
- unless headers.has_key?('Content-Type')
164
- headers['Content-Type'] = 'text/xml'
165
- end
166
-
167
- response = do_http_post(url, body.strip, params, headers)
168
-
169
- result = nil
170
- if response
171
- case response.code.to_i
172
- when 200
173
- result = Quickbooks::Model::RestResponse.from_xml(response.plain_body)
174
- when 401
175
- raise Quickbooks::IntuitRequestException.new("Authorization failure: token timed out?")
176
- when 404
177
- raise Quickbooks::IntuitRequestException.new("Resource Not Found: Check URL and try again")
178
- end
179
- end
180
- result
181
- end
182
-
183
162
  def do_http_post(url, body = "", params = {}, headers = {}) # throws IntuitRequestException
184
163
  url = add_query_string_to_url(url, params)
185
164
  do_http(:post, url, body, headers)
@@ -190,6 +169,23 @@ module Quickbooks
190
169
  do_http(:get, url, {}, headers)
191
170
  end
192
171
 
172
+ def do_http_file_upload(uploadIO, url, metadata = nil)
173
+ headers = {
174
+ 'Content-Type' => 'multipart/form-data'
175
+ }
176
+ body = {}
177
+ body['file_content_0'] = uploadIO
178
+
179
+ if metadata
180
+ standalone_prefix = '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>'
181
+ meta_data_xml = "#{standalone_prefix}\n#{metadata.to_xml_ns.to_s}"
182
+ param_part = UploadIO.new(StringIO.new(meta_data_xml), "application/xml")
183
+ body['file_metadata_0'] = param_part
184
+ end
185
+
186
+ do_http(:upload, url, body, headers)
187
+ end
188
+
193
189
  def do_http(method, url, body, headers) # throws IntuitRequestException
194
190
  if @oauth.nil?
195
191
  raise "OAuth client has not been initialized. Initialize with setter access_token="
@@ -216,6 +212,8 @@ module Quickbooks
216
212
  @oauth.get(url, headers)
217
213
  when :post
218
214
  @oauth.post(url, body, headers)
215
+ when :upload
216
+ @oauth.post_with_multipart(url, body, headers)
219
217
  else
220
218
  raise "Do not know how to perform that HTTP operation"
221
219
  end
@@ -0,0 +1,16 @@
1
+ module Quickbooks
2
+ module Service
3
+ class Deposit < BaseService
4
+
5
+ def delete(payment)
6
+ delete_by_query_string(payment)
7
+ end
8
+
9
+ private
10
+
11
+ def model
12
+ Quickbooks::Model::Deposit
13
+ end
14
+ end
15
+ end
16
+ end
@@ -6,8 +6,19 @@ module Quickbooks
6
6
  delete_by_query_string(invoice)
7
7
  end
8
8
 
9
+ def send(invoice, email_address=nil)
10
+ query = email_address.present? ? "?sendTo=#{email_address}" : ""
11
+ url = "#{url_for_resource(model::REST_RESOURCE)}/#{invoice.id}/send#{query}"
12
+ response = do_http_post(url,{})
13
+ if response.code.to_i == 200
14
+ model.from_xml(parse_singular_entity_response(model, response.plain_body))
15
+ else
16
+ nil
17
+ end
18
+ end
19
+
9
20
  private
10
-
21
+
11
22
  def model
12
23
  Quickbooks::Model::Invoice
13
24
  end
@@ -0,0 +1,35 @@
1
+ module Quickbooks
2
+ module Service
3
+ class Upload < BaseService
4
+
5
+ XML_NODE = "AttachableResponse"
6
+
7
+ # path_to_file: String - path to file
8
+ # mime_type: String - the MIME type of the file, e.g. image/jpeg
9
+ # attachable: Quickbooks::Model::Attachable meta-data details, can be null
10
+ def upload(path_to_file, mime_type, attachable = nil)
11
+ url = url_for_resource("upload")
12
+ uploadIO = UploadIO.new(path_to_file, mime_type)
13
+ response = do_http_file_upload(uploadIO, url, attachable)
14
+ prefix = "AttachableResponse/xmlns:Attachable"
15
+ if response.code.to_i == 200
16
+ model.from_xml(parse_singular_entity_response(model, response.plain_body, prefix))
17
+ else
18
+ nil
19
+ end
20
+ end
21
+
22
+ def download(uploadId)
23
+ url = url_for_resource("download/#{uploadId}")
24
+ do_http_get(url, {}, headers)
25
+ end
26
+
27
+ private
28
+
29
+ def model
30
+ Quickbooks::Model::Attachable
31
+ end
32
+
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,76 @@
1
+ module OauthMultipart
2
+ end
3
+
4
+ require "oauth"
5
+
6
+ OAuth::Consumer.class_eval do
7
+ def create_http_request_with_multipart(http_method, path, *arguments)
8
+ http_method = http_method.to_sym
9
+
10
+ if [:post, :put].include?(http_method)
11
+ data = arguments.shift
12
+ end
13
+
14
+ # if the base site contains a path, add it now
15
+ uri = URI.parse(site)
16
+ path = uri.path + path if uri.path
17
+
18
+ headers = arguments.first.is_a?(Hash) ? arguments.shift : {}
19
+
20
+ case http_method
21
+ when :post
22
+ request = Net::HTTP::Post.new(path,headers)
23
+ request["Content-Length"] = '0' # Default to 0
24
+ when :put
25
+ request = Net::HTTP::Put.new(path,headers)
26
+ request["Content-Length"] = '0' # Default to 0
27
+ when :get
28
+ request = Net::HTTP::Get.new(path,headers)
29
+ when :delete
30
+ request = Net::HTTP::Delete.new(path,headers)
31
+
32
+ when :head
33
+ request = Net::HTTP::Head.new(path,headers)
34
+ when :multipart_post
35
+ request = Net::HTTP::Post::Multipart.new(path, headers)
36
+ else
37
+ raise ArgumentError, "Don't know how to handle http_method: :#{http_method.to_s}"
38
+ end
39
+
40
+ if data.is_a?(Hash)
41
+ form_data = {}
42
+ data.each {|k,v| form_data[k.to_s] = v if !v.nil?}
43
+ request.set_form_data(form_data)
44
+ elsif data
45
+ if data.respond_to?(:read)
46
+ request.body_stream = data
47
+ if data.respond_to?(:length)
48
+ request["Content-Length"] = data.length.to_s
49
+ elsif data.respond_to?(:stat) && data.stat.respond_to?(:size)
50
+ request["Content-Length"] = data.stat.size.to_s
51
+ else
52
+ raise ArgumentError, "Don't know how to send a body_stream that doesn't respond to .length or .stat.size"
53
+ end
54
+ else
55
+ request.body = data.to_s
56
+ request["Content-Length"] = request.body.length.to_s
57
+ end
58
+ end
59
+
60
+ request
61
+
62
+ end
63
+
64
+ alias_method_chain :create_http_request, :multipart
65
+ end
66
+
67
+ OAuth::AccessToken.class_eval do
68
+
69
+ def post_with_multipart(*args)
70
+ multipart_post *args
71
+ end
72
+
73
+ def multipart_post(*args)
74
+ request(:multipart_post, *args)
75
+ end
76
+ end
@@ -1,5 +1,5 @@
1
1
  module Quickbooks
2
2
 
3
- VERSION = "0.1.9"
3
+ VERSION = "0.2.1"
4
4
 
5
5
  end
@@ -7,6 +7,7 @@ require 'uri'
7
7
  require 'date'
8
8
  require 'forwardable'
9
9
  require 'oauth'
10
+ require 'net/http/post/multipart'
10
11
  require 'quickbooks/util/collection'
11
12
  require 'quickbooks/util/logging'
12
13
  require 'quickbooks/util/http_encoding_helper'
@@ -23,6 +24,9 @@ require 'quickbooks/model/has_line_items'
23
24
  require 'quickbooks/model/access_token_response'
24
25
  require 'quickbooks/model/meta_data'
25
26
  require 'quickbooks/model/class'
27
+ require 'quickbooks/model/entity_ref'
28
+ require 'quickbooks/model/attachable_ref'
29
+ require 'quickbooks/model/attachable'
26
30
  require 'quickbooks/model/custom_field'
27
31
  require 'quickbooks/model/sales_item_line_detail'
28
32
  require 'quickbooks/model/sub_total_line_detail'
@@ -43,6 +47,9 @@ require 'quickbooks/model/journal_entry'
43
47
  require 'quickbooks/model/item'
44
48
  require 'quickbooks/model/account'
45
49
  require 'quickbooks/model/check_payment'
50
+ require 'quickbooks/model/deposit_line_detail'
51
+ require 'quickbooks/model/deposit_line_item'
52
+ require 'quickbooks/model/deposit'
46
53
  require 'quickbooks/model/credit_card_payment'
47
54
  require 'quickbooks/model/telephone_number'
48
55
  require 'quickbooks/model/other_contact_info'
@@ -75,6 +82,7 @@ require 'quickbooks/model/purchase'
75
82
  require 'quickbooks/model/purchase_order'
76
83
  require 'quickbooks/model/vendor_credit'
77
84
  require 'quickbooks/model/estimate'
85
+ require 'quickbooks/model/delivery_info'
78
86
  require 'quickbooks/model/invoice'
79
87
  require 'quickbooks/model/tax_rate'
80
88
  require 'quickbooks/model/tax_rate_detail'
@@ -97,10 +105,12 @@ require 'quickbooks/service/service_crud'
97
105
  require 'quickbooks/service/base_service'
98
106
  require 'quickbooks/service/access_token'
99
107
  require 'quickbooks/service/class'
108
+ require 'quickbooks/service/attachable'
100
109
  require 'quickbooks/service/company_info'
101
110
  require 'quickbooks/service/customer'
102
111
  require 'quickbooks/service/department'
103
112
  require 'quickbooks/service/invoice'
113
+ require 'quickbooks/service/deposit'
104
114
  require 'quickbooks/service/item'
105
115
  require 'quickbooks/service/journal_entry'
106
116
  require 'quickbooks/service/sales_receipt'
@@ -125,6 +135,8 @@ require 'quickbooks/service/preferences'
125
135
  require 'quickbooks/service/refund_receipt'
126
136
  require 'quickbooks/service/invoice_change'
127
137
  require 'quickbooks/service/customer_change'
138
+ require 'quickbooks/service/upload'
139
+ require 'quickbooks/util/multipart'
128
140
  require 'quickbooks/service/vendor_change'
129
141
  require 'quickbooks/service/item_change'
130
142
 
metadata CHANGED
@@ -1,43 +1,43 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: quickbooks-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Caughlan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-24 00:00:00.000000000 Z
11
+ date: 2015-03-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: oauth
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: '0'
19
+ version: 0.4.7
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: '0'
26
+ version: 0.4.7
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: roxml
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: '0'
33
+ version: 3.3.1
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: '0'
40
+ version: 3.3.1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: nokogiri
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -67,33 +67,47 @@ dependencies:
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: rake
70
+ name: multipart-post
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - '>='
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
- type: :development
76
+ type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - '>='
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rake
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - '='
88
+ - !ruby/object:Gem::Version
89
+ version: 10.1.0
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - '='
95
+ - !ruby/object:Gem::Version
96
+ version: 10.1.0
83
97
  - !ruby/object:Gem::Dependency
84
98
  name: simplecov
85
99
  requirement: !ruby/object:Gem::Requirement
86
100
  requirements:
87
- - - '>='
101
+ - - '='
88
102
  - !ruby/object:Gem::Version
89
- version: '0'
103
+ version: 0.7.1
90
104
  type: :development
91
105
  prerelease: false
92
106
  version_requirements: !ruby/object:Gem::Requirement
93
107
  requirements:
94
- - - '>='
108
+ - - '='
95
109
  - !ruby/object:Gem::Version
96
- version: '0'
110
+ version: 0.7.1
97
111
  - !ruby/object:Gem::Dependency
98
112
  name: rr
99
113
  requirement: !ruby/object:Gem::Requirement
@@ -126,16 +140,16 @@ dependencies:
126
140
  name: fakeweb
127
141
  requirement: !ruby/object:Gem::Requirement
128
142
  requirements:
129
- - - '>='
143
+ - - '='
130
144
  - !ruby/object:Gem::Version
131
- version: '0'
145
+ version: 1.3.0
132
146
  type: :development
133
147
  prerelease: false
134
148
  version_requirements: !ruby/object:Gem::Requirement
135
149
  requirements:
136
- - - '>='
150
+ - - '='
137
151
  - !ruby/object:Gem::Version
138
- version: '0'
152
+ version: 1.3.0
139
153
  - !ruby/object:Gem::Dependency
140
154
  name: guard
141
155
  requirement: !ruby/object:Gem::Requirement
@@ -173,6 +187,8 @@ files:
173
187
  - lib/quickbooks/model/access_token_response.rb
174
188
  - lib/quickbooks/model/account.rb
175
189
  - lib/quickbooks/model/account_based_expense_line_detail.rb
190
+ - lib/quickbooks/model/attachable.rb
191
+ - lib/quickbooks/model/attachable_ref.rb
176
192
  - lib/quickbooks/model/base_model.rb
177
193
  - lib/quickbooks/model/base_reference.rb
178
194
  - lib/quickbooks/model/batch_request.rb
@@ -191,13 +207,18 @@ files:
191
207
  - lib/quickbooks/model/custom_field.rb
192
208
  - lib/quickbooks/model/customer.rb
193
209
  - lib/quickbooks/model/customer_change.rb
210
+ - lib/quickbooks/model/delivery_info.rb
194
211
  - lib/quickbooks/model/department.rb
212
+ - lib/quickbooks/model/deposit.rb
213
+ - lib/quickbooks/model/deposit_line_detail.rb
214
+ - lib/quickbooks/model/deposit_line_item.rb
195
215
  - lib/quickbooks/model/discount_line_detail.rb
196
216
  - lib/quickbooks/model/discount_override.rb
197
217
  - lib/quickbooks/model/document_numbering.rb
198
218
  - lib/quickbooks/model/email_address.rb
199
219
  - lib/quickbooks/model/employee.rb
200
220
  - lib/quickbooks/model/entity.rb
221
+ - lib/quickbooks/model/entity_ref.rb
201
222
  - lib/quickbooks/model/estimate.rb
202
223
  - lib/quickbooks/model/fault.rb
203
224
  - lib/quickbooks/model/global_tax_calculation.rb
@@ -240,6 +261,7 @@ files:
240
261
  - lib/quickbooks/model/term.rb
241
262
  - lib/quickbooks/model/time_activity.rb
242
263
  - lib/quickbooks/model/transaction_tax_detail.rb
264
+ - lib/quickbooks/model/upload.rb
243
265
  - lib/quickbooks/model/validator.rb
244
266
  - lib/quickbooks/model/vendor.rb
245
267
  - lib/quickbooks/model/vendor_change.rb
@@ -247,6 +269,7 @@ files:
247
269
  - lib/quickbooks/model/web_site_address.rb
248
270
  - lib/quickbooks/service/access_token.rb
249
271
  - lib/quickbooks/service/account.rb
272
+ - lib/quickbooks/service/attachable.rb
250
273
  - lib/quickbooks/service/base_service.rb
251
274
  - lib/quickbooks/service/batch.rb
252
275
  - lib/quickbooks/service/bill.rb
@@ -257,6 +280,7 @@ files:
257
280
  - lib/quickbooks/service/customer.rb
258
281
  - lib/quickbooks/service/customer_change.rb
259
282
  - lib/quickbooks/service/department.rb
283
+ - lib/quickbooks/service/deposit.rb
260
284
  - lib/quickbooks/service/employee.rb
261
285
  - lib/quickbooks/service/estimate.rb
262
286
  - lib/quickbooks/service/invoice.rb
@@ -276,12 +300,14 @@ files:
276
300
  - lib/quickbooks/service/tax_rate.rb
277
301
  - lib/quickbooks/service/term.rb
278
302
  - lib/quickbooks/service/time_activity.rb
303
+ - lib/quickbooks/service/upload.rb
279
304
  - lib/quickbooks/service/vendor.rb
280
305
  - lib/quickbooks/service/vendor_change.rb
281
306
  - lib/quickbooks/service/vendor_credit.rb
282
307
  - lib/quickbooks/util/collection.rb
283
308
  - lib/quickbooks/util/http_encoding_helper.rb
284
309
  - lib/quickbooks/util/logging.rb
310
+ - lib/quickbooks/util/multipart.rb
285
311
  - lib/quickbooks/util/name_entity.rb
286
312
  - lib/quickbooks/util/query_builder.rb
287
313
  - lib/quickbooks/version.rb