File tree Expand file tree Collapse file tree 5 files changed +18
-3
lines changed Expand file tree Collapse file tree 5 files changed +18
-3
lines changed Original file line number Diff line number Diff line change 11Changelog
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
Original file line number Diff line number Diff line change @@ -277,10 +277,10 @@ Converting an object to JSON data:
277277
278278Loading 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 )
Original file line number Diff line number Diff line change @@ -102,6 +102,7 @@ def __init__(self):
102102class 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
Original file line number Diff line number Diff 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 )
1414version = '.' .join (map (str , VERSION ))
1515
1616setup (
Original file line number Diff line number Diff 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 )
You can’t perform that action at this time.
0 commit comments