add support to milti transaction
This commit is contained in:
@@ -71,6 +71,7 @@ class Order(BaseModel):
|
||||
address: Address
|
||||
items: tuple[Item, ...]
|
||||
payment_method: PaymentMethod
|
||||
discount: Decimal = Decimal('0')
|
||||
cpf: str | None = None
|
||||
cnpj: str | None = None
|
||||
|
||||
@@ -127,6 +128,7 @@ class Iugu:
|
||||
}
|
||||
for item in order.items
|
||||
]
|
||||
|
||||
payload = {
|
||||
'order_id': order.id,
|
||||
'external_reference': order.id,
|
||||
@@ -135,6 +137,7 @@ class Iugu:
|
||||
'email': order.email,
|
||||
'payable_with': order.payment_method.lower(),
|
||||
'notification_url': postback_url.geturl(),
|
||||
'discount_cents': int(order.discount * -100),
|
||||
'payer': {
|
||||
'name': order.name,
|
||||
'email': order.email,
|
||||
|
||||
Reference in New Issue
Block a user