Skip to content

Commit dc9f147

Browse files
Manuel HuezManuel Huez
authored andcommitted
Add support for addons. Improve pagination. Simplify function signatures. Bump to API version 1.4.0.0
1 parent 8cb46d2 commit dc9f147

31 files changed

+3293
-329
lines changed

processout/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33

44
# Import resources
55
from processout.activity import Activity
6+
from processout.addon import Addon
7+
from processout.apirequest import APIRequest
8+
from processout.apiversion import APIVersion
69
from processout.authorizationrequest import AuthorizationRequest
710
from processout.card import Card
811
from processout.cardinformation import CardInformation
@@ -16,13 +19,16 @@
1619
from processout.invoice import Invoice
1720
from processout.invoicedetail import InvoiceDetail
1821
from processout.customeraction import CustomerAction
22+
from processout.dunningaction import DunningAction
1923
from processout.plan import Plan
2024
from processout.product import Product
2125
from processout.project import Project
2226
from processout.refund import Refund
2327
from processout.subscription import Subscription
2428
from processout.transaction import Transaction
29+
from processout.transactionoperation import TransactionOperation
2530
from processout.webhook import Webhook
31+
from processout.webhookendpoint import WebhookEndpoint
2632

2733
from processout.gatewayrequest import GatewayRequest
2834

processout/activity.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def __init__(self, client, prefill = None):
1616

1717
self._id = None
1818
self._project = None
19+
self._project_id = None
1920
self._title = None
2021
self._content = None
2122
self._level = None
@@ -47,6 +48,10 @@ def project(self, val):
4748
"""Set project
4849
Keyword argument:
4950
val -- New project value"""
51+
if val is None:
52+
self._project = val
53+
return self
54+
5055
if isinstance(val, dict):
5156
obj = processout.Project(self._client)
5257
obj.fill_with_data(val)
@@ -55,6 +60,19 @@ def project(self, val):
5560
self._project = val
5661
return self
5762

63+
@property
64+
def project_id(self):
65+
"""Get project_id"""
66+
return self._project_id
67+
68+
@project_id.setter
69+
def project_id(self, val):
70+
"""Set project_id
71+
Keyword argument:
72+
val -- New project_id value"""
73+
self._project_id = val
74+
return self
75+
5876
@property
5977
def title(self):
6078
"""Get title"""
@@ -116,6 +134,8 @@ def fill_with_data(self, data):
116134
self.id = data["id"]
117135
if "project" in data.keys():
118136
self.project = data["project"]
137+
if "project_id" in data.keys():
138+
self.project_id = data["project_id"]
119139
if "title" in data.keys():
120140
self.title = data["title"]
121141
if "content" in data.keys():

0 commit comments

Comments
 (0)