paypalPayment static method
Future<void>
paypalPayment({
- required BuildContext context,
- required String clientId,
- required String secretKey,
- required List<
Map< transactions,String, dynamic> > - bool sandboxMode = true,
- String? note,
- String paymentGatewayName = "PayPal",
- dynamic onShowToast()?,
- dynamic onPaymentSuccess()?,
- dynamic onPaymentFailure()?,
- dynamic onPaymentCancel()?,
PayPal Payment
Implementation
static Future<void> paypalPayment({
required BuildContext context,
required String clientId,
required String secretKey,
required List<Map<String, dynamic>> transactions,
bool sandboxMode = true,
String? note,
String paymentGatewayName = "PayPal",
Function()? onShowToast,
Function()? onPaymentSuccess,
Function()? onPaymentFailure,
Function()? onPaymentCancel,
}) async {
return PaypalService().openPaypal(
context: context,
clientId: clientId,
secretKey: secretKey,
transactions: transactions,
sandboxMode: sandboxMode,
note: note,
paymentGatewayName: paymentGatewayName,
onShowToast: onShowToast,
onPaymentSuccess: onPaymentSuccess,
onPaymentFailure: onPaymentFailure,
onPaymentCancel: onPaymentCancel,
);
}