Skip to content

Commit 827832c

Browse files
authored
Merge pull request #352 from ej2/0.9.8
0.9.8
2 parents 93450fc + 89a38ac commit 827832c

File tree

5 files changed

+18
-3
lines changed

5 files changed

+18
-3
lines changed

CHANGELOG.rst

+4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
Changelog
22
=========
3+
* 0.9.7 (May 20, 2024)
4+
* Added ItemAccountRef to SalesItemLineDetail
5+
* Updated from_json example in readme
6+
37
* 0.9.7 (March 12, 2024)
48
* Update intuit-oauth dependency
59
* Updated CompanyCurrency to ref to use Code instead of Id

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -277,10 +277,10 @@ Converting an object to JSON data:
277277

278278
Loading JSON data into a quickbooks object:
279279

280-
account = Account()
281-
account.from_json(
280+
account = Account.from_json(
282281
{
283282
"AccountType": "Accounts Receivable",
283+
"AcctNum": "123123",
284284
"Name": "MyJobs"
285285
}
286286
)

quickbooks/objects/detailline.py

+2
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ def __init__(self):
102102
class SalesItemLineDetail(QuickbooksBaseObject):
103103
class_dict = {
104104
"ItemRef": Ref,
105+
"ItemAccountRef": Ref,
105106
"ClassRef": Ref,
106107
"TaxCodeRef": Ref,
107108
"PriceLevelRef": Ref,
@@ -117,6 +118,7 @@ def __init__(self):
117118

118119
self.MarkupInfo = None
119120
self.ItemRef = None
121+
self.ItemAccountRef = None
120122
self.ClassRef = None
121123
self.TaxCodeRef = None
122124
self.PriceLevelRef = None

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def read(*parts):
1010
return fp.read()
1111

1212

13-
VERSION = (0, 9, 7)
13+
VERSION = (0, 9, 8)
1414
version = '.'.join(map(str, VERSION))
1515

1616
setup(

tests/integration/test_account.py

+9
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,12 @@ def test_update(self):
3232

3333
query_account = Account.get(account.Id, qb=self.qb_client)
3434
self.assertEqual(query_account.Name, "Updated Name {0}".format(self.account_number))
35+
36+
def test_create_using_from_json(self):
37+
account = Account.from_json({
38+
"AcctNum": self.account_number,
39+
"Name": self.name,
40+
"AccountSubType": "CashOnHand"
41+
})
42+
43+
account.save(qb=self.qb_client)

0 commit comments

Comments
 (0)