paywithpayazaflutter

Last updated:

0 purchases

paywithpayazaflutter Image
paywithpayazaflutter Images
Add to Cart

Description:

paywithpayazaflutter

Need to integrate a payment checkout engine for you flutter app? This package is the easiest way to do it
Features #
Pay with transfer. Pay with card and pay with bank coming soon
Getting started #
In order to use this package for your app, you will need to use the onGenerateRoute system for routing,
this is because you will have to pass both your checkout page name route and your callback page name route.
Upon payment successful, you will receieve a string json as a returned value on your callback page
Usage #
class RouteGenerator{
static Route<dynamic> generateRoute(RouteSettings settings){
final args = settings.arguments;

switch(settings.name){
case '/':
return MaterialPageRoute(builder: (_) => Checkout());
case '/checkout':
return MaterialPageRoute(builder: (_) => Checkout());
case '/callback':
if(args is String){
return MaterialPageRoute(
builder: (_) => CallbackPage(response: args)
);
}

return _errorRoute();
default:
return _errorRoute();
}
}

static Route<dynamic> _errorRoute(){
return MaterialPageRoute(builder: (_){
return Scaffold(
body: Center(
child: Text('Error'),
),
);
});
}
}
copied to clipboard
Additional information #

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.