netsuite 0.4.4 → 0.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +8 -8
- data/Gemfile +2 -1
- data/lib/netsuite.rb +6 -1
- data/lib/netsuite/actions/search.rb +7 -0
- data/lib/netsuite/configuration.rb +1 -0
- data/lib/netsuite/namespaces/tran_emp.rb +11 -0
- data/lib/netsuite/records/customer.rb +4 -2
- data/lib/netsuite/records/customer_currency.rb +28 -0
- data/lib/netsuite/records/customer_currency_list.rb +9 -0
- data/lib/netsuite/records/customer_payment.rb +1 -1
- data/lib/netsuite/records/customer_refund.rb +1 -1
- data/lib/netsuite/records/discount_item.rb +1 -1
- data/lib/netsuite/records/invoice.rb +3 -1
- data/lib/netsuite/records/job_status.rb +25 -0
- data/lib/netsuite/records/sales_order.rb +2 -1
- data/lib/netsuite/records/time_bill.rb +32 -0
- data/lib/netsuite/support/country.rb +1 -0
- data/lib/netsuite/support/record_refs.rb +7 -2
- data/lib/netsuite/support/search_result.rb +2 -2
- data/lib/netsuite/version.rb +1 -1
- data/spec/netsuite/records/basic_record_spec.rb +54 -0
- data/spec/netsuite/records/customer_spec.rb +2 -2
- metadata +9 -4
- data/spec/netsuite/records/currency_spec.rb +0 -11
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
YzkxNzQxZDQ4MWIwMDY1NDBmOTMzOTljYjliYTY4NmE3ZWQyNzMzZg==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NjBkY2E4YmU0ODQ4Y2VhMTY1Mzc2YTQ5MTc5NmU2YjNjOTUyMjczOA==
|
|
7
7
|
SHA512:
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
M2QyMTRjNjYyODAyNjE2OTNkNWFhMWY5ZTc4N2VlM2YxNzA1M2M2MmQ1ZWEy
|
|
10
|
+
MTdhMmY2Y2I5ZDFiOTM2YjMwNmYzY2UxMThmODYzOWYyMGUyMjQ0YzVkOGQ4
|
|
11
|
+
MmZjYmMzYTA5MDM2NjQ5YjRkMDYxMWYzYTI1OGMxN2RiNTIwM2U=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
OThiMjMzZjEwZjUzYmE5YjU5YWIwZTliOTAwYmVjZmFjYjIzMjUxYTQ5NTQ5
|
|
14
|
+
MjQwYzBiZTAxZGQ4YTFmYWRmZjlkMTExZWU2MTYwM2JlMWQ0YzJjZjI3OWI5
|
|
15
|
+
NGY1NzAyMTA4ZjA4MmU4ODI0MGQ5MTgxNjVkMDAwNDg3MDE1Njk=
|
data/Gemfile
CHANGED
data/lib/netsuite.rb
CHANGED
|
@@ -21,6 +21,7 @@ module NetSuite
|
|
|
21
21
|
autoload :PlatformCore, 'netsuite/namespaces/platform_core'
|
|
22
22
|
autoload :TranBank, 'netsuite/namespaces/tran_bank'
|
|
23
23
|
autoload :TranCust, 'netsuite/namespaces/tran_cust'
|
|
24
|
+
autoload :TranEmp, 'netsuite/namespaces/tran_emp'
|
|
24
25
|
autoload :TranGeneral, 'netsuite/namespaces/tran_general'
|
|
25
26
|
autoload :TranInvt, 'netsuite/namespaces/tran_invt'
|
|
26
27
|
autoload :TranSales, 'netsuite/namespaces/tran_sales'
|
|
@@ -95,6 +96,8 @@ module NetSuite
|
|
|
95
96
|
autoload :Customer, 'netsuite/records/customer'
|
|
96
97
|
autoload :CustomerAddressbook, 'netsuite/records/customer_addressbook'
|
|
97
98
|
autoload :CustomerAddressbookList, 'netsuite/records/customer_addressbook_list'
|
|
99
|
+
autoload :CustomerCurrency, 'netsuite/records/customer_currency'
|
|
100
|
+
autoload :CustomerCurrencyList, 'netsuite/records/customer_currency_list'
|
|
98
101
|
autoload :CustomerDeposit, 'netsuite/records/customer_deposit'
|
|
99
102
|
autoload :CustomerPayment, 'netsuite/records/customer_payment'
|
|
100
103
|
autoload :CustomerPaymentApply, 'netsuite/records/customer_payment_apply'
|
|
@@ -138,6 +141,7 @@ module NetSuite
|
|
|
138
141
|
autoload :ItemFulfillmentPackageList, 'netsuite/records/item_fulfillment_package_list'
|
|
139
142
|
autoload :ItemMember, 'netsuite/records/item_member'
|
|
140
143
|
autoload :Job, 'netsuite/records/job'
|
|
144
|
+
autoload :JobStatus, 'netsuite/records/job_status'
|
|
141
145
|
autoload :JournalEntry, 'netsuite/records/journal_entry'
|
|
142
146
|
autoload :JournalEntryLine, 'netsuite/records/journal_entry_line'
|
|
143
147
|
autoload :JournalEntryLineList, 'netsuite/records/journal_entry_line_list'
|
|
@@ -169,6 +173,7 @@ module NetSuite
|
|
|
169
173
|
autoload :TaxType, 'netsuite/records/tax_type'
|
|
170
174
|
autoload :Task, 'netsuite/records/task'
|
|
171
175
|
autoload :Term, 'netsuite/records/term'
|
|
176
|
+
autoload :TimeBill, 'netsuite/records/time_bill'
|
|
172
177
|
autoload :Transaction, 'netsuite/records/transaction'
|
|
173
178
|
autoload :UnitsType, 'netsuite/records/units_type'
|
|
174
179
|
autoload :UnitsTypeUomList, 'netsuite/records/units_type_uom_list'
|
|
@@ -194,7 +199,7 @@ module NetSuite
|
|
|
194
199
|
def self.configure_from_env(&block)
|
|
195
200
|
NetSuite.configure do
|
|
196
201
|
reset!
|
|
197
|
-
|
|
202
|
+
|
|
198
203
|
email ENV['NETSUITE_EMAIL'] unless ENV['NETSUITE_EMAIL'].nil?
|
|
199
204
|
password ENV['NETSUITE_PASSWORD'] unless ENV['NETSUITE_PASSWORD'].nil?
|
|
200
205
|
account ENV['NETSUITE_ACCOUNT'] unless ENV['NETSUITE_ACCOUNT'].nil?
|
|
@@ -148,6 +148,13 @@ module NetSuite
|
|
|
148
148
|
elsif condition[:value].is_a?(Array) && condition[:type] == 'SearchDateField'
|
|
149
149
|
# date ranges are handled via searchValue (start range) and searchValue2 (end range)
|
|
150
150
|
|
|
151
|
+
h[element_name] = {
|
|
152
|
+
'@operator' => condition[:operator],
|
|
153
|
+
"platformCore:searchValue" => condition[:value].first.to_s,
|
|
154
|
+
"platformCore:searchValue2" => condition[:value].last.to_s
|
|
155
|
+
}
|
|
156
|
+
elsif condition[:value].is_a?(Array) && condition[:operator] == 'between'
|
|
157
|
+
|
|
151
158
|
h[element_name] = {
|
|
152
159
|
'@operator' => condition[:operator],
|
|
153
160
|
"platformCore:searchValue" => condition[:value].first.to_s,
|
|
@@ -122,6 +122,7 @@ module NetSuite
|
|
|
122
122
|
'xmlns:listAcct' => "urn:accounting_#{api_version}.lists.webservices.netsuite.com",
|
|
123
123
|
'xmlns:tranBank' => "urn:bank_#{api_version}.transactions.webservices.netsuite.com",
|
|
124
124
|
'xmlns:tranCust' => "urn:customers_#{api_version}.transactions.webservices.netsuite.com",
|
|
125
|
+
'xmlns:tranEmp' => "urn:employees_#{api_version}.transactions.webservices.netsuite.com",
|
|
125
126
|
'xmlns:tranInvt' => "urn:inventory_#{api_version}.transactions.webservices.netsuite.com",
|
|
126
127
|
'xmlns:listSupport' => "urn:support_#{api_version}.lists.webservices.netsuite.com",
|
|
127
128
|
'xmlns:tranGeneral' => "urn:general_#{api_version}.transactions.webservices.netsuite.com",
|
|
@@ -14,7 +14,7 @@ module NetSuite
|
|
|
14
14
|
fields :account_number, :aging, :alt_email, :alt_name, :alt_phone, :bill_pay,
|
|
15
15
|
:buying_reason, :buying_time_frame, :campaign_category, :click_stream, :comments, :company_name,
|
|
16
16
|
:consol_aging, :consol_days_overdue, :contrib_pct, :credit_cards_list, :credit_hold_override,
|
|
17
|
-
:credit_limit, :
|
|
17
|
+
:credit_limit, :date_created, :days_overdue, :default_address,
|
|
18
18
|
:download_list, :email, :email_preference, :email_transactions, :end_date, :entity_id,
|
|
19
19
|
:estimated_budget, :fax, :fax_transactions, :first_name, :first_visit, :give_access, :global_subscription_status,
|
|
20
20
|
:group_pricing_list, :home_phone, :image, :is_budget_approved, :is_inactive, :is_person, :item_pricing_list, :keywords,
|
|
@@ -23,13 +23,15 @@ module NetSuite
|
|
|
23
23
|
:password, :password2, :phone, :phonetic_name, :pref_cc_processor, :print_on_check_as,
|
|
24
24
|
:print_transactions, :referrer, :reminder_days, :representing_subsidiary, :require_pwd_change, :resale_number,
|
|
25
25
|
:sales_group, :sales_readiness, :sales_team_list, :salutation, :send_email, :ship_complete, :shipping_item,
|
|
26
|
-
:stage, :start_date, :
|
|
26
|
+
:stage, :start_date, :sync_partner_teams, :tax_exempt, :tax_item, :taxable,
|
|
27
27
|
:territory, :third_party_acct, :third_party_country, :third_party_zipcode, :title, :url,
|
|
28
28
|
:vat_reg_number, :visits, :web_lead
|
|
29
29
|
|
|
30
30
|
field :addressbook_list, CustomerAddressbookList
|
|
31
31
|
field :custom_field_list, CustomFieldList
|
|
32
32
|
field :contact_roles_list, ContactAccessRolesList
|
|
33
|
+
field :currency_list, CustomerCurrencyList
|
|
34
|
+
# TODO subscriptions_list
|
|
33
35
|
|
|
34
36
|
read_only_fields :balance, :consol_balance, :deposit_balance, :consol_deposit_balance, :overdue_balance,
|
|
35
37
|
:consol_overdue_balance, :unbilled_orders, :consol_unbilled_orders
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
module NetSuite
|
|
2
|
+
module Records
|
|
3
|
+
class CustomerCurrency
|
|
4
|
+
include Support::Fields
|
|
5
|
+
include Support::RecordRefs
|
|
6
|
+
include Support::Records
|
|
7
|
+
include Namespaces::ListRel
|
|
8
|
+
|
|
9
|
+
# https://system.netsuite.com/help/helpcenter/en_US/srbrowser/Browser2014_1/schema/other/customercurrency.html?mode=package
|
|
10
|
+
|
|
11
|
+
fields :balance, :consol_balance, :consol_deposit_balance, :consol_overdue_balance,
|
|
12
|
+
:consol_unbilled_orders, :deposit_balance, :display_symbol, :overdue_balance,
|
|
13
|
+
:override_currency_format, :symbol_placement, :unbilled_orders
|
|
14
|
+
|
|
15
|
+
record_refs :currency
|
|
16
|
+
|
|
17
|
+
def initialize(attributes_or_record = {})
|
|
18
|
+
case attributes_or_record
|
|
19
|
+
when Hash
|
|
20
|
+
initialize_from_attributes_hash(attributes_or_record)
|
|
21
|
+
when self.class
|
|
22
|
+
initialize_from_record(attributes_or_record)
|
|
23
|
+
end
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
end
|
|
@@ -21,7 +21,7 @@ module NetSuite
|
|
|
21
21
|
read_only_fields :applied, :balance, :pending, :total, :unapplied
|
|
22
22
|
|
|
23
23
|
record_refs :account, :ar_acct, :credit_card, :credit_card_processor, :custom_form, :customer, :department, :klass,
|
|
24
|
-
:location, :payment_method, :posting_period, :subsidiary
|
|
24
|
+
:location, :payment_method, :posting_period, :subsidiary, :currency
|
|
25
25
|
|
|
26
26
|
attr_reader :internal_id
|
|
27
27
|
attr_accessor :external_id
|
|
@@ -20,7 +20,7 @@ module NetSuite
|
|
|
20
20
|
read_only_fields :balance, :total
|
|
21
21
|
|
|
22
22
|
record_refs :account, :ar_acct, :credit_card, :credit_card_processor, :custom_form, :customer, :department, :klass,
|
|
23
|
-
:location, :payment_method, :posting_period, :subsidiary, :void_journal
|
|
23
|
+
:location, :payment_method, :posting_period, :subsidiary, :void_journal, :currency
|
|
24
24
|
|
|
25
25
|
attr_reader :internal_id
|
|
26
26
|
attr_accessor :external_id
|
|
@@ -7,7 +7,7 @@ module NetSuite
|
|
|
7
7
|
include Support::Actions
|
|
8
8
|
include Namespaces::ListAcct
|
|
9
9
|
|
|
10
|
-
actions :get, :get_list, :add, :delete, :search, :upsert
|
|
10
|
+
actions :get, :get_list, :add, :update, :delete, :search, :upsert
|
|
11
11
|
|
|
12
12
|
fields :available_to_partners, :created_date, :description, :display_name, :include_children, :is_inactive, :is_pre_tax,
|
|
13
13
|
:item_id, :last_modified_date, :non_posting, :rate, :upc_code, :vendor_name
|
|
@@ -7,6 +7,8 @@ module NetSuite
|
|
|
7
7
|
include Support::Actions
|
|
8
8
|
include Namespaces::TranSales
|
|
9
9
|
|
|
10
|
+
# https://system.netsuite.com/help/helpcenter/en_US/srbrowser/Browser2014_1/schema/record/invoice.html?mode=package
|
|
11
|
+
|
|
10
12
|
actions :get, :get_list, :initialize, :add, :update, :delete, :upsert, :search
|
|
11
13
|
|
|
12
14
|
fields :balance, :bill_address,
|
|
@@ -40,7 +42,7 @@ module NetSuite
|
|
|
40
42
|
|
|
41
43
|
record_refs :account, :bill_address_list, :custom_form, :department, :entity, :klass, :partner,
|
|
42
44
|
:posting_period, :ship_address_list, :terms, :location, :sales_rep, :tax_item, :created_from,
|
|
43
|
-
:ship_method, :lead_source, :promo_code, :subsidiary
|
|
45
|
+
:ship_method, :lead_source, :promo_code, :subsidiary, :currency
|
|
44
46
|
|
|
45
47
|
attr_reader :internal_id
|
|
46
48
|
attr_accessor :external_id
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
module NetSuite
|
|
2
|
+
module Records
|
|
3
|
+
class JobStatus
|
|
4
|
+
include Support::Fields
|
|
5
|
+
include Support::RecordRefs
|
|
6
|
+
include Support::Records
|
|
7
|
+
include Support::Actions
|
|
8
|
+
include Namespaces::ListRel
|
|
9
|
+
|
|
10
|
+
actions :get, :get_list, :add, :delete, :search, :update, :upsert
|
|
11
|
+
|
|
12
|
+
fields :description, :is_inactive, :name
|
|
13
|
+
|
|
14
|
+
attr_reader :internal_id
|
|
15
|
+
attr_accessor :external_id
|
|
16
|
+
|
|
17
|
+
def initialize(attributes = {})
|
|
18
|
+
@internal_id = attributes.delete(:internal_id) || attributes.delete(:@internal_id)
|
|
19
|
+
@external_id = attributes.delete(:external_id) || attributes.delete(:@external_id)
|
|
20
|
+
initialize_from_attributes_hash(attributes)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
end
|
|
24
|
+
end
|
|
25
|
+
end
|
|
@@ -17,7 +17,8 @@ module NetSuite
|
|
|
17
17
|
:rev_rec_on_rev_commitment, :sales_effective_date, :ship_date, :shipping_cost, :shipping_tax1_rate, :shipping_tax2_rate, :source,
|
|
18
18
|
:start_date, :status, :sync_partner_teams, :sync_sales_teams, :tax2_total, :tax_rate, :to_be_emailed, :to_be_faxed,
|
|
19
19
|
:to_be_printed, :total_cost_estimate, :tran_date, :tran_id, :tran_is_vsoe_bundle, :vat_reg_num,
|
|
20
|
-
:vsoe_auto_calc, :
|
|
20
|
+
:linked_tracking_numbers, :vsoe_auto_calc, :quantity, :bill_city, :bill_state, :ship_city, :ship_state, :cost_estimate,
|
|
21
|
+
:amount, :is_ship_address
|
|
21
22
|
|
|
22
23
|
field :transaction_ship_address, ShipAddress
|
|
23
24
|
field :transaction_bill_address, BillAddress
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
module NetSuite
|
|
2
|
+
module Records
|
|
3
|
+
class TimeBill
|
|
4
|
+
include Support::Fields
|
|
5
|
+
include Support::RecordRefs
|
|
6
|
+
include Support::Records
|
|
7
|
+
include Support::Actions
|
|
8
|
+
include Namespaces::TranEmp
|
|
9
|
+
|
|
10
|
+
actions :get, :get_list, :add, :delete, :search, :update, :upsert
|
|
11
|
+
|
|
12
|
+
fields :created_date, :is_billable, :last_modified_date, :memo, :override_rate, :paid_externally, :rate, :status,
|
|
13
|
+
:supervisor_approval, :tran_date, :time_type
|
|
14
|
+
|
|
15
|
+
field :custom_field_list, CustomFieldList
|
|
16
|
+
field :hours, Duration
|
|
17
|
+
|
|
18
|
+
record_refs :employee, :customer, :case_task_event, :payroll_item, :workplace, :item, :department, :location, :price,
|
|
19
|
+
:subsidiary, :temporary_local_jurisdiction, :temporary_state_jurisdiction
|
|
20
|
+
|
|
21
|
+
attr_reader :internal_id
|
|
22
|
+
attr_accessor :external_id
|
|
23
|
+
|
|
24
|
+
def initialize(attributes = {})
|
|
25
|
+
@internal_id = attributes.delete(:internal_id) || attributes.delete(:@internal_id)
|
|
26
|
+
@external_id = attributes.delete(:external_id) || attributes.delete(:@external_id)
|
|
27
|
+
initialize_from_attributes_hash(attributes)
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -9,12 +9,17 @@ module NetSuite
|
|
|
9
9
|
module ClassMethods
|
|
10
10
|
|
|
11
11
|
def record_refs(*names)
|
|
12
|
-
names.
|
|
13
|
-
|
|
12
|
+
if names.empty?
|
|
13
|
+
@record_refs ||= Set.new
|
|
14
|
+
else
|
|
15
|
+
names.each do |name|
|
|
16
|
+
record_ref name
|
|
17
|
+
end
|
|
14
18
|
end
|
|
15
19
|
end
|
|
16
20
|
|
|
17
21
|
def record_ref(name)
|
|
22
|
+
record_refs << name
|
|
18
23
|
field name, NetSuite::Records::RecordRef
|
|
19
24
|
end
|
|
20
25
|
|
|
@@ -29,7 +29,7 @@ module NetSuite
|
|
|
29
29
|
if response.body.has_key?(:record_list)
|
|
30
30
|
# basic search results
|
|
31
31
|
record_list = response.body[:record_list][:record]
|
|
32
|
-
record_list = [record_list]
|
|
32
|
+
record_list = [record_list] unless record_list.is_a?(Array)
|
|
33
33
|
|
|
34
34
|
record_list.each do |record|
|
|
35
35
|
results << result_class.new(record)
|
|
@@ -37,7 +37,7 @@ module NetSuite
|
|
|
37
37
|
elsif response.body.has_key? :search_row_list
|
|
38
38
|
# advanced search results
|
|
39
39
|
record_list = response.body[:search_row_list][:search_row]
|
|
40
|
-
record_list = [record_list]
|
|
40
|
+
record_list = [record_list] unless record_list.is_a?(Array)
|
|
41
41
|
|
|
42
42
|
record_list.each do |record|
|
|
43
43
|
# TODO because of customFieldList we need to either make this recursive
|
data/lib/netsuite/version.rb
CHANGED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
require 'spec_helper'
|
|
2
|
+
|
|
3
|
+
describe 'basic records' do
|
|
4
|
+
let(:basic_record_list) {
|
|
5
|
+
[
|
|
6
|
+
NetSuite::Records::Currency,
|
|
7
|
+
NetSuite::Records::Location,
|
|
8
|
+
NetSuite::Records::JobStatus,
|
|
9
|
+
NetSuite::Records::TimeBill,
|
|
10
|
+
NetSuite::Records::Customer
|
|
11
|
+
]
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
it 'can be initialized, has fields, and can be converted into a record' do
|
|
15
|
+
basic_record_list.each do |record_class|
|
|
16
|
+
record_instance = record_class.new
|
|
17
|
+
|
|
18
|
+
# most records have a
|
|
19
|
+
expect(record_class.fields.size).to be > 0
|
|
20
|
+
expect(record_class.record_refs).to_not be_nil
|
|
21
|
+
expect(record_instance).to respond_to(:internal_id)
|
|
22
|
+
|
|
23
|
+
# NOTE all records have externalIds, not testing exernalId setter
|
|
24
|
+
if record_class.respond_to?(:upsert)
|
|
25
|
+
expect(record_instance).to respond_to(:external_id)
|
|
26
|
+
expect(record_instance).to respond_to(:external_id=)
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
standard_fields = (record_class.fields - record_class.record_refs).to_a
|
|
30
|
+
custom_object_fields = standard_fields.select { |f| !record_instance.send(f).nil? }
|
|
31
|
+
standard_fields -= custom_object_fields
|
|
32
|
+
|
|
33
|
+
# ensure that all fields can be set
|
|
34
|
+
standard_fields.each { |f| expect(record_instance).to have_field(f) }
|
|
35
|
+
record_class.record_refs.each { |f| expect(record_instance).to have_record_ref(f) }
|
|
36
|
+
|
|
37
|
+
# TODO handle custom object fields
|
|
38
|
+
|
|
39
|
+
6.times do
|
|
40
|
+
record_instance.send(:"#{standard_fields.sample}=", "Test Value")
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
if !record_class.record_refs.empty?
|
|
44
|
+
sample_record_ref_field = record_class.record_refs.to_a.sample
|
|
45
|
+
|
|
46
|
+
record_instance.send(:"#{sample_record_ref_field}=".to_sym, { internal_id: 1 })
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
expect(record_instance.to_record).to be_a(Hash)
|
|
50
|
+
|
|
51
|
+
# TODO should test for correct value output
|
|
52
|
+
end
|
|
53
|
+
end
|
|
54
|
+
end
|
|
@@ -9,7 +9,7 @@ describe NetSuite::Records::Customer do
|
|
|
9
9
|
:buying_reason, :buying_time_frame, :campaign_category, :click_stream, :comments, :company_name,
|
|
10
10
|
:consol_aging, :consol_balance, :consol_days_overdue, :consol_deposit_balance, :consol_overdue_balance,
|
|
11
11
|
:consol_unbilled_orders, :contrib_pct, :credit_cards_list, :credit_hold_override, :credit_limit,
|
|
12
|
-
:
|
|
12
|
+
:date_created, :days_overdue, :default_address,
|
|
13
13
|
:deposit_balance, :download_list, :email, :email_preference, :email_transactions, :end_date, :entity_id,
|
|
14
14
|
:estimated_budget, :fax, :fax_transactions, :first_name, :first_visit, :give_access, :global_subscription_status,
|
|
15
15
|
:group_pricing_list, :home_phone, :image, :is_budget_approved, :is_inactive, :is_person, :item_pricing_list, :keywords,
|
|
@@ -18,7 +18,7 @@ describe NetSuite::Records::Customer do
|
|
|
18
18
|
:password, :password2, :phone, :phonetic_name, :pref_cc_processor,:print_on_check_as,
|
|
19
19
|
:print_transactions, :referrer, :reminder_days, :representing_subsidiary, :require_pwd_change, :resale_number,
|
|
20
20
|
:sales_group, :sales_readiness, :sales_team_list, :salutation, :send_email, :ship_complete, :shipping_item,
|
|
21
|
-
:stage, :start_date, :
|
|
21
|
+
:stage, :start_date, :sync_partner_teams, :tax_exempt, :tax_item, :taxable,
|
|
22
22
|
:territory, :third_party_acct, :third_party_country, :third_party_zipcode, :title, :unbilled_orders, :url,
|
|
23
23
|
:vat_reg_number, :visits, :web_lead
|
|
24
24
|
].each do |field|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: netsuite
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ryan Moran
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2015-08-
|
|
12
|
+
date: 2015-08-27 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: savon
|
|
@@ -84,6 +84,7 @@ files:
|
|
|
84
84
|
- lib/netsuite/namespaces/setup_custom.rb
|
|
85
85
|
- lib/netsuite/namespaces/tran_bank.rb
|
|
86
86
|
- lib/netsuite/namespaces/tran_cust.rb
|
|
87
|
+
- lib/netsuite/namespaces/tran_emp.rb
|
|
87
88
|
- lib/netsuite/namespaces/tran_general.rb
|
|
88
89
|
- lib/netsuite/namespaces/tran_invt.rb
|
|
89
90
|
- lib/netsuite/namespaces/tran_purch.rb
|
|
@@ -129,6 +130,8 @@ files:
|
|
|
129
130
|
- lib/netsuite/records/customer.rb
|
|
130
131
|
- lib/netsuite/records/customer_addressbook.rb
|
|
131
132
|
- lib/netsuite/records/customer_addressbook_list.rb
|
|
133
|
+
- lib/netsuite/records/customer_currency.rb
|
|
134
|
+
- lib/netsuite/records/customer_currency_list.rb
|
|
132
135
|
- lib/netsuite/records/customer_deposit.rb
|
|
133
136
|
- lib/netsuite/records/customer_payment.rb
|
|
134
137
|
- lib/netsuite/records/customer_payment_apply.rb
|
|
@@ -167,6 +170,7 @@ files:
|
|
|
167
170
|
- lib/netsuite/records/item_fulfillment_package_list.rb
|
|
168
171
|
- lib/netsuite/records/item_member.rb
|
|
169
172
|
- lib/netsuite/records/job.rb
|
|
173
|
+
- lib/netsuite/records/job_status.rb
|
|
170
174
|
- lib/netsuite/records/journal_entry.rb
|
|
171
175
|
- lib/netsuite/records/journal_entry_line.rb
|
|
172
176
|
- lib/netsuite/records/journal_entry_line_list.rb
|
|
@@ -198,6 +202,7 @@ files:
|
|
|
198
202
|
- lib/netsuite/records/task.rb
|
|
199
203
|
- lib/netsuite/records/tax_type.rb
|
|
200
204
|
- lib/netsuite/records/term.rb
|
|
205
|
+
- lib/netsuite/records/time_bill.rb
|
|
201
206
|
- lib/netsuite/records/transaction.rb
|
|
202
207
|
- lib/netsuite/records/units_type.rb
|
|
203
208
|
- lib/netsuite/records/units_type_uom.rb
|
|
@@ -243,6 +248,7 @@ files:
|
|
|
243
248
|
- spec/netsuite/records/account_spec.rb
|
|
244
249
|
- spec/netsuite/records/accounting_period_spec.rb
|
|
245
250
|
- spec/netsuite/records/assembly_item_spec.rb
|
|
251
|
+
- spec/netsuite/records/basic_record_spec.rb
|
|
246
252
|
- spec/netsuite/records/bill_address_spec.rb
|
|
247
253
|
- spec/netsuite/records/billing_schedule_milestone_list_spec.rb
|
|
248
254
|
- spec/netsuite/records/billing_schedule_milestone_spec.rb
|
|
@@ -262,7 +268,6 @@ files:
|
|
|
262
268
|
- spec/netsuite/records/credit_memo_item_list_spec.rb
|
|
263
269
|
- spec/netsuite/records/credit_memo_item_spec.rb
|
|
264
270
|
- spec/netsuite/records/credit_memo_spec.rb
|
|
265
|
-
- spec/netsuite/records/currency_spec.rb
|
|
266
271
|
- spec/netsuite/records/custom_field_list_spec.rb
|
|
267
272
|
- spec/netsuite/records/custom_field_spec.rb
|
|
268
273
|
- spec/netsuite/records/custom_list_spec.rb
|
|
@@ -412,6 +417,7 @@ test_files:
|
|
|
412
417
|
- spec/netsuite/records/account_spec.rb
|
|
413
418
|
- spec/netsuite/records/accounting_period_spec.rb
|
|
414
419
|
- spec/netsuite/records/assembly_item_spec.rb
|
|
420
|
+
- spec/netsuite/records/basic_record_spec.rb
|
|
415
421
|
- spec/netsuite/records/bill_address_spec.rb
|
|
416
422
|
- spec/netsuite/records/billing_schedule_milestone_list_spec.rb
|
|
417
423
|
- spec/netsuite/records/billing_schedule_milestone_spec.rb
|
|
@@ -431,7 +437,6 @@ test_files:
|
|
|
431
437
|
- spec/netsuite/records/credit_memo_item_list_spec.rb
|
|
432
438
|
- spec/netsuite/records/credit_memo_item_spec.rb
|
|
433
439
|
- spec/netsuite/records/credit_memo_spec.rb
|
|
434
|
-
- spec/netsuite/records/currency_spec.rb
|
|
435
440
|
- spec/netsuite/records/custom_field_list_spec.rb
|
|
436
441
|
- spec/netsuite/records/custom_field_spec.rb
|
|
437
442
|
- spec/netsuite/records/custom_list_spec.rb
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe NetSuite::Records::Account do
|
|
4
|
-
let(:currency) { NetSuite::Records::Currency.new }
|
|
5
|
-
|
|
6
|
-
it 'can be initialized and has fields' do
|
|
7
|
-
expect(currency.class.fields.size).to be > 0
|
|
8
|
-
|
|
9
|
-
currency.class.fields.each { |f| expect(currency).to have_field(f) }
|
|
10
|
-
end
|
|
11
|
-
end
|