Skip to content

White blank screen showing after success or close button pressed #232

@ishteyaque06

Description

@ishteyaque06

Description

White blank screen showing whenever payment is success or if tapping on close button.

Razorpay pod Version :

I have installed through SPM and version number is 1.4.2

Xcode Version :

Xcode 16.0

What you did:

I have initiated SDK with as suggested in sample. SDK open and I completed the subscription transaction, but after that sucess delegate method is not called.

razorpay = RazorpayCheckout.initWithKey("Id", andDelegate: self)
        guard let amount = self.viewModel.selectedItem?.amount else {return}
        guard let orderId = self.viewModel.subscribeModel?.output?.orderId else {return}
        let options: [AnyHashable:Any] = [
            "amount":Int(amount),
            "currency":self.viewModel.selectedItem?.currency,
            "name":"Name",
            "subscription_id":orderId,
            "prefill": [
                "contact": RemoteConfig.shared.getUserInfo()?.settings?.userNumber,
                "email": RemoteConfig.shared.getUserInfo()?.profile?.email
                           ],
        ]
        if let rzp = self.razorpay {
            rzp.open(options)
         //Also try rzp.open(options,displayController:self)
        } else {
            print("Unable to initialize")
        }

And then set delegate method

extension SubscriptionViewController:RazorpayPaymentCompletionProtocol{
    func onPaymentError(_ code: Int32, description str: String) {
        self.showAlert(title: str)
    }
    
    func onPaymentSuccess(_ payment_id: String) {
        self.viewModel.verifyPayment(paymentId: payment_id)
    }
    
}

What happened:

A White blank screen shown

Image

Image

Image

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

  1. Open SDK
  2. Press close button

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions