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

Payment screen not opening #7

Closed
OMARIHAMZA opened this issue Apr 4, 2021 · 12 comments
Closed

Payment screen not opening #7

OMARIHAMZA opened this issue Apr 4, 2021 · 12 comments

Comments

@OMARIHAMZA
Copy link

I'm trying to integrate flutter_paytabs_bridge: ^2.0.1-beta into my Flutter app.

I added the config parameters as described in the documentation, but when I try to start the payment nothing happens in the app!

P.S.

  • The library requested phone permissions
  • I'm running on Android 10
  • These lines get printed in the terminal

I/System.out( 728): PaymentSdkFragment onCreateView: PaymentSdkConfigurationDetails(profileId=63854, serverKey=****-****-****, clientKey=****-****-****-****, billingDetails=PaymentSdkBillingDetails(city=city, countryCode=country, email=billing email, name=billing name, phone=billing phone, state=state, addressLine=address line, zip=zip code), shippingDetails=com.payment.paymentsdk.integrationmodels.PaymentSdkShippingDetails@726ec3a, locale=AR, cartId=25, currencyCode=SAR, cartDescription=cart desc, transactionType=sale, transactionClass=ecom, amount=20.0, screenTitle=Pay with Card, customerIp=255.255.255.255, tokeniseType=NONE, tokenFormat=null, token=, transactionReference=, logo=null, showBillingInfo=false, showShippingInfo=false, forceShippingInfoValidation=false, merchantCountry=SA, hideCardScanner=false) D/ForceDarkHelper( 728): updateByCheckExcludeList: pkg: com.rqwah.user activity: com.payment.paymentsdk.PaymentSdkActivity@31a32e7

Thanks in advance!

@mohamedkhairy953
Copy link
Contributor

Hello
Did you receive anything from the flutter cllback
It may be some validation error which returns to you through the callback

@OMARIHAMZA
Copy link
Author

Hello Mohamed,

Thanks for your response.

I printed the callback result and I got this error:

{code: -1, data: null, message: Invalid merchant country code (it should be alpha-2 ISO code), status: error}

My config is as follows:

var configuration = PaymentSdkConfigurationDetails( profileId: "myid", serverKey: "secret-secret-secret", clientKey: "secret-secret-secret-secret", cartId: "25", cartDescription: "cart desc", merchantName: "Mhd", screentTitle: "Pay with Card", billingDetails: billingDetails, shippingDetails: shippingDetails, locale: PaymentSdkLocale.EN, amount: 20.0, currencyCode: "SAR", merchantCountryCode: "SA", );

What is the correct alpha-2 ISO code for Saudi Arabia?

@mohamedkhairy953
Copy link
Contributor

mohamedkhairy953 commented Apr 5, 2021 via email

@mohamedkhairy953
Copy link
Contributor

mohamedkhairy953 commented Apr 5, 2021 via email

@OMARIHAMZA
Copy link
Author

OK, thanks.

Please do let me know once you find the cause of the problem :)

@mohamedkhairy953
Copy link
Contributor

mohamedkhairy953 commented Apr 5, 2021

Hello , Could you please tell me what device you are using to reproduce this issue, and do me a favor and try on another device and let me know.

@OMARIHAMZA
Copy link
Author

I tested it on 2 devices: Xiaomi mi mix 3 & AVD (Pixel 3a API 29).

The issue occurs in both devices.

@mohamedkhairy953
Copy link
Contributor

We've published a new version 2.0.2-beta, please upgrade your version and try again

@OMARIHAMZA
Copy link
Author

I upgraded the library to flutter_paytabs_bridge: ^2.0.2-beta

Nothing has changed.

{code: -1, data: null, message: Invalid billing country code, status: error}

@mohamedkhairy953
Copy link
Contributor

mohamedkhairy953 commented Apr 5, 2021 via email

@OMARIHAMZA
Copy link
Author

I thought the problem was from the config object! Didn't know that the address object was causing it!

Thank you very much Mohamed for your help!

@mohamedkhairy953
Copy link
Contributor

mohamedkhairy953 commented Apr 5, 2021 via email

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

2 participants