Skip to content

Commit

Permalink
new payment gateway
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan-g committed Nov 29, 2023
1 parent 7b99f08 commit e1bebae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions say/api/payment_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ def post(self, data: NewPaymentSchema):
payment.credit_amount -= configs.MIN_BANK_AMOUNT - payment.bank_amount

# idpay gateway
if newGateway is None:
if second_gateWay is None:
api_data = {
"order_id": payment.order_id,
"amount": payment.bank_amount,
Expand All @@ -230,7 +230,7 @@ def post(self, data: NewPaymentSchema):
payment.link = transaction["link"]

# zibal gateway
if newGateway:
if second_gateWay:
zibal_request = zibal.request(payment.bank_amount, payment.order_id, desc)
if zibal_request["result"] != 100:
raise HTTPException(
Expand Down

0 comments on commit e1bebae

Please sign in to comment.