launchWavePayment function
Implementation
Future<void> launchWavePayment(BuildContext context, String url) async {
final Uri paymentUri = Uri.parse(url);
final messenger = ScaffoldMessenger.of(context);
if (await canLaunchUrl(paymentUri)) {
await launchUrl(paymentUri, mode: LaunchMode.externalApplication);
} else {
messenger.showSnackBar(
const SnackBar(content: Text("Impossible d’ouvrir le lien de paiement.")),
);
}
}