Skip to content

Commit

Permalink
Merge pull request #352 from ej2/0.9.8
Browse files Browse the repository at this point in the history
0.9.8
  • Loading branch information
ej2 authored May 20, 2024
2 parents 93450fc + 89a38ac commit 827832c
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
Changelog
=========
* 0.9.7 (May 20, 2024)
* Added ItemAccountRef to SalesItemLineDetail
* Updated from_json example in readme

* 0.9.7 (March 12, 2024)
* Update intuit-oauth dependency
* Updated CompanyCurrency to ref to use Code instead of Id
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -277,10 +277,10 @@ Converting an object to JSON data:

Loading JSON data into a quickbooks object:

account = Account()
account.from_json(
account = Account.from_json(
{
"AccountType": "Accounts Receivable",
"AcctNum": "123123",
"Name": "MyJobs"
}
)
Expand Down
2 changes: 2 additions & 0 deletions quickbooks/objects/detailline.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ def __init__(self):
class SalesItemLineDetail(QuickbooksBaseObject):
class_dict = {
"ItemRef": Ref,
"ItemAccountRef": Ref,
"ClassRef": Ref,
"TaxCodeRef": Ref,
"PriceLevelRef": Ref,
Expand All @@ -117,6 +118,7 @@ def __init__(self):

self.MarkupInfo = None
self.ItemRef = None
self.ItemAccountRef = None
self.ClassRef = None
self.TaxCodeRef = None
self.PriceLevelRef = None
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def read(*parts):
return fp.read()


VERSION = (0, 9, 7)
VERSION = (0, 9, 8)
version = '.'.join(map(str, VERSION))

setup(
Expand Down
9 changes: 9 additions & 0 deletions tests/integration/test_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,12 @@ def test_update(self):

query_account = Account.get(account.Id, qb=self.qb_client)
self.assertEqual(query_account.Name, "Updated Name {0}".format(self.account_number))

def test_create_using_from_json(self):
account = Account.from_json({
"AcctNum": self.account_number,
"Name": self.name,
"AccountSubType": "CashOnHand"
})

account.save(qb=self.qb_client)

0 comments on commit 827832c

Please sign in to comment.