Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug after making payment through net banking #193

Open
jonathanjr3 opened this issue Jul 25, 2023 · 0 comments
Open

Bug after making payment through net banking #193

jonathanjr3 opened this issue Jul 25, 2023 · 0 comments

Comments

@jonathanjr3
Copy link

Description

A "Payment Successful" page shows up after making a payment through Netbanking which doesn't dismiss itself automatically:

WhatsApp Image 2023-07-21 at 12 54 19 PM

Clicking on "Cancel" here doesn't dismiss the page either:

WhatsApp Image 2023-07-21 at 12 54 16 PM

As a workaround we are getting the top most view controller and dismissing it manually inside the onPaymentSuccess delegate method of RazorpayPaymentCompletionProtocol

This workaround doesn't work when the "Success" button here is tapped twice quickly, the "Payment Successful" page just stays there:

WhatsApp Image 2023-07-21 at 12 54 22 PM

All of this were tested in testing environment, we haven't checked this in production yet. The payment itself is working fine, only the payment successful page is not getting dismissed automatically.
This was working fine till razorpay version 1.3.2

Razorpay pod Version :

Version 1.3.3

Xcode Version :

14.3.1 (14E300c)

What you did:

  • Choose 'Netbanking' for payment mode in the razorpay payment page
  • Choose any bank
  • Click on 'Success' in the demo bank page

What happened:

  • A 'Payment Successful' page shows up and doesn't get dismissed automatically

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

  1. Intialize RazorpayCheckout object with RazorpayCheckout.initWithKey(razorpayAPIKey, andDelegate: self)
  2. Open payment view with razorpay.open(params, displayController: self)
  3. Choose 'Netbanking' for payment mode in the razorpay payment page
  4. Choose any bank
  5. Click on 'Success' in the demo bank page

Suggested solution:

  • Get the top most view controller and dismiss it manually inside the onPaymentSuccess delegate method of RazorpayPaymentCompletionProtocol
  • Note that this doesn't work when the 'Success' button is tapped twice quickly in the 'demo bank' page

Code example, screenshot, or link to a repository:

var param = [String: Any]()
param["name"] = "NameOfCompany"
param["currency"] = currencyvalue
param["order_id"] = orderId
        
var prefill = [String: Any]()
prefill["name"] = firstname
prefill["email"] = email
prefill["contact"] = mobile
param["prefill"] = prefill
        
var notes = [String: Any]()
notes["order_id"] = orderId
param["notes"] = notes
        
var theme = [String: Any]()
theme["image_frame"] = false
param["theme"] = theme
let razorpay = RazorpayCheckout.initWithKey(razorpayAPIKey, andDelegate: self)
razorpay.open(param, displayController: self)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant